-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve user interface #195
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #195 +/- ##
==========================================
- Coverage 88.09% 88.00% -0.09%
==========================================
Files 44 44
Lines 2083 2118 +35
==========================================
+ Hits 1835 1864 +29
- Misses 248 254 +6 ☔ View full report in Codecov by Sentry. |
Coverage reportClick to see where and how coverage changed
This report was generated by python-coverage-comment-action |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job @kallewesterling, this is exactly what I was thinking about.
Two high level things:
- Could we put this into a separate module to keep
compare
clean? - What would be great eventually (though no need for this now if you're tight on time) is to check whether
autoemulate
is run in a notebook and if so display the table withdisplay(HTML(df.to_html()))
fromfrom IPython.display
, which looks a bit nicer.
|
Ah sorry, I wasn't very clear. I think it's good to have it as a Good question with the checking for whether it's run in a notebook. I couldn't find a super clear answer either. I'll have a closer look tomorrow, but both versions seem to work. |
Fixed the high-level (1) above in 6dab835 |
Fixed (2) in daec70f |
OK @mastoffel I think that's all the stuff addressed! Check out the branch now :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice @kallewesterling , notebook printing looks great, and printing.py
is a good place for this.
Just one more comment below.
try: | ||
__IPYTHON__ | ||
_in_ipython_session = True | ||
except NameError: | ||
_in_ipython_session = False |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
works well for me
autoemulate/printing.py
Outdated
"Simulation input shape (X)", | ||
"Simulation output shape (y)", | ||
"# training set samples (train_idxs)", | ||
"# test set samples (test_idxs)", | ||
"Do hyperparameter search (param_search)", | ||
"Type of hyperparameter search (search_type)", | ||
"# sampled parameter settings (param_search_iters)", | ||
"Scale data before fitting (scale)", | ||
"Scaler (scaler)", | ||
"Dimensionality reduction before fitting (reduce_dim)", | ||
"Dimensionality reduction method (dim_reducer)", | ||
"Cross-validation strategy (cv)", | ||
"# folds (folds)", | ||
"# parallel jobs (n_jobs)", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
one after thought here: Maybe this would be most useful if the argument names (rather than attribute names) would be in brackets. Would you agree?
If so, the two things to change are:
"# training set samples (train_idxs)",
"# test set samples (test_idxs)",
to
"test set size (test_set_size)"
(and the value could be 20% or 0.2)
and
"Cross-validation strategy (cv)",
to
"Cross-validation strategy (fold_strategy)",
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, that makes sense. I was thinking that these should refer to any properties that exist on the object (hence, cv
instead of fold_strategy
as self.cv
has been set; same with train_idxs
and test_idxs
as those are also existing as properties, whereas test_set_size
is not a property on the object)... But since we're just showing the setup settings, I suppose it makes sense!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See: c0504de
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, thanks @kallewesterling ! Feel free to merge!
Fixes #159.