Giter VIP home page Giter VIP logo

experiments-viewer's Introduction

experiments-viewer's People

Contributors

greenkeeper[bot] avatar lonnen avatar openjck avatar pyup-bot avatar rafrombrc avatar renovate-bot avatar renovate[bot] avatar robhudson avatar spasovski avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

experiments-viewer's Issues

Update metric types

I'm going to be changing the metric types to return the same thing I'm getting upstream. Which will change from ['categorical', 'numerical'] to a more descriptive set that looks like ['EnumeratedHistogram', 'FlagHistogram', 'CountHistogram', 'BooleanHistogram', 'ExponentialHistogram'].

This will involve both front-end and back-end changes.

Data migrations to support new data

In the current data model we separate categorical and numerical data into separate tables. The only difference between the two is that the categorical data includes a rank field for the front-end to show certain buckets first for the CDF charts. I declare we no longer need this, and if we do we can do it at SQL query time.

Without this we can combine the tables and simplify a lot of the import logic and database logic and Django ORM code.

Initial Update

Hi ๐Ÿ‘Š

This is my first visit to this fine repo, but it seems you have been working hard to keep all dependencies updated so far.

Once you have closed this issue, I'll create seperate pull requests for every update as soon as I find one.

That's it for now!

Happy merging! ๐Ÿค–

Backfill metadata for metrics that came down w/o any

The experiments viewer will end up with many more metrics than the distribution viewer, most of which we don't have in our database.

On encountering new metrics the plan is to add them to our list of metrics in the database, so they will then have an id and a source_name. The fields for name, description, tooltip, and type would remain empty and should/could be populated in some other way at a future date. Without these fields the front-end can simply display the source_name as the name and default to a basic tooltip showing the values.

This bug is to figure out if there is a better upstream source for this metadata about the metrics. Or if we want to create one that various tools pull from. Or other thoughts that come up we can discuss here.

Irrelevant cohorts show up in rollover text

On stage, Exp 1 has a cohort named "group A" and Exp 2 has a cohort named "group B". If you start w Exp 1 and roll over the graphs, the text across the bottom bar shows you the values for "group A" and "control". If you switch to Exp 2, "group A" disappears and is replace by "group B", but "group A" still shows up in the rollover text across the bottom bar.

Show experiments in order in the dropdown

For example, the experiment with ID 1 would be shown first, 2 second, and so on. It might be easiest to do this on the back-end and have the API guarantee this order.

Add octocat link to github repo

This is to allow viewer to submit bugs or see the code or contribute.

Gregg suggests putting it in the top nav area somewhere.

Return 404 instead of 500 when Collection can't be found

Currently when the front-end queries for a metric in a dataset that doesn't exist, Django throws a 500 with "DoesNotExist: Collection matching query does not exist." It would be preferable if we handled this more nicely and returned a 404 instead.

Refactor subgroups

Subgroup data is now accessible through Redux thanks to the work Davor did recently. I'll refactor the front-end code to grab subgroups that way now, rather than the way it has done it in the past.

Some cohort lines aren't visible

On staging right now, group B in experiment 2 looks like it should be showing up in the graphs, but it doesn't. It might be that the lines aren't rendering, but it also might be that cohort got assigned the color black and it's just invisible against the black background. In either case, it needs to be fixed so that cohorts are always visible.

Add table for statistics data

Add a table at the same level as api_point to store statistics data coming from Sunah.

Suggested schema:

api_statistics
- id
- collection_id
- comparison_branch
- name
- p_value
- value

Cohort legend doesn't update w experiment change

  1. Hit staging site, see "Exp 1" selected w 'group A' and 'control' both displayed, and they're both showing up in the color legend.

  2. Select "Exp 2" from drop-down, hit 'apply' button. 'group B' shows up in the cohort list, but the color legend doesn't update, it still shows 'group A' from before.

Use a name other than "subgroup"

We use the name subgroup on the front-end to refer to cohorts. But because we also want to use this platform elsewhere, where there may not be cohorts per se, we ideally want to use a word that would make sense for both. In other words, a term that means (cohort|population).

What would be a good name for this? Is population a generic term? @robhudson @spasovski

Move auth logic to its own Django app

This may go away in the future if we pick up an auth0 lib. Having is separated would be good preparation and also good modularity for our code base.

Don't hardcode cohort colors

We shouldn't hardcode a [cohort name] -> [cohort color] mapping in this project since we won't know the cohort names ahead of time.

For now, we can assign each cohort a random color except for control, which should always be the same color. Down the road, we can open an issue to make sure all cohorts have consistent colors (for example, group A would always be red and group B would always be blue) but to do that without knowing the names ahead of time we would have to have some kind of repeatable hash from name to color value. But that's outside the scope of this issue.

Update import to add subgroups

This involves iterating over all subgroups for each branch and creating a new api_collection with population being a concatenation of branch + subgroup.

Add subgroup to dataset API

Currently we have:

{
  "datasets": [
    {
      "id": 1,
      "name": "Experiment 1",
      "populations": ["control", "group A"]
    },
    ...
  ]
}

I propose we update to have a subgroup key with list of subgroups included:

{
  "datasets": [
    {
      "id": 1,
      "name": "Experiment 1",
      "populations": ["control", "group A"],
      "subgroups": ["Windows", "Mac", "Linux", "Other"]
    },
    ....
  ]
}

Add support for experiments and cohort selection

It should be possible to configure experiments and cohorts on the main page. Only one experiment can be chosen at a time. One or many cohorts can be chosen at a time. By default all cohorts will be selected. The list of possible cohorts that the user will be able to choose from will depend on the experiment that is chosen.

Experiments are essentially datasets. Each experiment has one or more metrics associated with it. Cohorts are essentially populations. For each cohort, another line will appear in the chart and another item will appear in the legend.

These options could be presented in the existing Configuration box or as separate widgets: for example, Experiment could be a simple drop-down and Cohorts could be a multi-select box.

Cohorts should default to all on

When switching from experiment A to experiment B, it looks like a) any cohort in exp B that matches a cohort name from exp A will retain the "on/off" state that was set in exp A, and b) any cohort in exp B that does not exist in exp A will default to "off". Ideally, when switching to a new experiment, all cohorts for that new experiment will always default to "on".

"apply" button needs to be hit twice

Currently on staging when I use the drop down to choose an experiment and then hit the "apply" button nothing seems to happen. Only when I hit "apply" a second time does the page update and show the new experiment as expected.

Revisit chart detail page

The chart detail page does not load when navigated to directly, for example by clicking this link.

When the chart detail page is navigated to from within the app (that is, by loading the homepage and then clicking on a chart), the detail page itself loads but the chart within it does not.

I think the former, at least, is due to the new default URL handling.

Don't load dataset 1 by default

At the moment, the front-end always tries to load dataset 1 on first load. But there's no guarantee that dataset 1 will exist. Instead, it should load the [0]th dataset listed in /datasets.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.