Skip to content
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

[MRG] New widget to adjust default smoothing value in gui #924

Merged

Conversation

dylansdaniels
Copy link
Collaborator

Title says it all

@dylansdaniels dylansdaniels force-pushed the gui_default_smoothing_field branch from 8fe7718 to 0fde5c0 Compare November 8, 2024 14:36
@asoplata asoplata added the hnn-gui HNN GUI label Nov 15, 2024
@asoplata asoplata added this to the 0.4 milestone Nov 15, 2024
@dylansdaniels dylansdaniels changed the title [WIP] New widget to adjust default smoothing value in gui [MRG] New widget to adjust default smoothing value in gui Nov 21, 2024
@@ -937,6 +944,11 @@ def data(self):
"figs": self.figs
}

@property
def fig_default_params(self):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this need to be @property? Seems like the other ones were created to regroup existing attributes for code cleanliness, whereas here you're just returning self.fig_defaults

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made it a @Property so I could call it in the test:
viz_smooth_value = gui.viz_manager.fig_default_params['default_smoothing']

gui_smooth_value = gui.fig_default_params['default_smoothing']
viz_smooth_value = gui.viz_manager.fig_default_params['default_smoothing']

assert gui_smooth_value == new_smoothing
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It'd be useful to add a similar assert for the original smooth values of the fig_default and viz_manager

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I follow you, just updated 👍

Copy link
Collaborator

@asoplata asoplata left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Tested and works, even for subsequent runs in-session

@asoplata asoplata merged commit 8c1351e into jonescompneurolab:master Nov 22, 2024
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hnn-gui HNN GUI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants