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

[BUG] The GUI does not allow negative values in key parameter boxes #192

Closed
AdrianAriasAbreu opened this issue Apr 30, 2024 · 1 comment · Fixed by #193
Closed

[BUG] The GUI does not allow negative values in key parameter boxes #192

AdrianAriasAbreu opened this issue Apr 30, 2024 · 1 comment · Fixed by #193
Labels
bug Something isn't working

Comments

@AdrianAriasAbreu
Copy link

Describe the bug
The default parameters in the Graphical User Interface (GUI) do not match with those in the Command Line Interface (CLI), resulting in inconsistent alignment outcomes depending on whether alignment is computed through the GUI or CLI.

Based on the documentation negative values set the units in pixels while positive values set values in millimeters (mm).
https://brainglobe.info/documentation/brainreg/user-guide/parameters.html

The real issue is that the GUI only accepts positive values for parameters like grid_spacing, smoothing_sigma_reference, and smoothing_sigma_floating, making it impossible to input negative values.

To Reproduce
Compute any alignment in CLI and GUI and then compare the outcomes.

Expected behaviour
Same outcomes regardless the use of CLI or GUI.

Log file
brainreg_2024-04-26_09-49-50_CLI.log
brainreg_2024-04-26_10-16-26_GUI.log

Key parameters when using CLI:

  • grid_spacing: -10
  • smoothing_sigma_reference: -1.0
  • smoothing_sigma_floating: -1.0

Key parameters when using GUI:

  • grid_spacing: 10
  • smoothing_sigma_reference: 1
  • smoothing_sigma_floating: 1.0

Screenshots
Alignment when using CLI
image
Alignment when using GUI
image

Computer used

  • OS: Windows 10 Pro

Conclusion
The GUI does not allow negative values in the parameter boxes for grid_spacing, smoothing_sigma_reference, and smoothing_sigma_floating.

@AdrianAriasAbreu AdrianAriasAbreu added the bug Something isn't working label Apr 30, 2024
@adamltyson
Copy link
Member

Thanks for raising this @AdrianAriasAbreu. Having looked into this, the plugin was actually making these parameters negative when running the registration. The UI was incorrect and confusing though, so I've corrected this in #193 to match the CLI.

I also noticed another small difference between the napari plugin and the CLI when it comes to downsampling data. I think this explains the differences you see, not the parameter issue. This is also fixed in #193. On some test data of mine, this makes the GUI and CLI produce the same results, so I would be interested to see the results on your data too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants