pymmcore-plus / pymmcore-widgets

A set of Qt-based widgets onto the pymmcore-plus model
https://pymmcore-plus.github.io/pymmcore-widgets
Other
12 stars 7 forks source link

GridPlanWidget buttons set incorrect bounds #337

Closed gselzer closed 4 months ago

gselzer commented 4 months ago

Description

Using the Stage Control, we tried to set up a Grid Plan using the MDAWidget. When we clicked on the corner buttons, we found: Button Bound 1 Bound 2
top left top right
top right top bottom
bottom left left right
bottom right left bottom
left right
right bottom
top top
bottom left

What I Did

  1. Started up my UI
  2. Opened up Stage Control (A combination of StageWidgets) and MDA (an MDAWidget)
  3. Moved to `(X, Y)=(20, 20)
  4. Clicked the Top Left button

This resulted in the state below:

image

fdrgsp commented 4 months ago

Hi @gselzer! I think this is because we are using a cartesian coordinate system where top left is (-x +y) and bottom right is (+x -y). Therefore you need to transpose your stage axis in the micromanager properties of the stage (e.g. you can open the PropertyBrowser widget and set it from there). Does it make sense?

And then to match the movement in the stage widget, just toggle the Invert X and/or Invert Y checkboxes.

gselzer commented 4 months ago

Hi @gselzer! I think this is because we are using a cartesian coordinate system where top left is (-x +y) and bottom right is (+x -y). Therefore you need to transpose your stage axis in the micromanager properties of the stage (e.g. you can open the PropertyBrowser widget and set it from there). Does it make sense?

And then to match the movement in the stage widget, just toggle the Invert X and/or Invert Y checkboxes.

Hi @fdrgsp! I tried toggling XYTransposeMirror-X, but this did not change things. Furthermore, I do not believe that any toggling could resolve that the Top Right button sets both the top and bottom border. Am I missing something? I'd be happy to dig deeper once I finish filing some additional issues

tlambert03 commented 4 months ago

Therefore you need to transpose your stage axis in the micromanager properties of the stage (e.g. you can open the PropertyBrowser widget and set it from there). Does it make sense?

shouldn't we be able to deal with whatever the user enters? That is: regardless of how they've set up the microscope, if they mark top/bottom/left/right in any way, shouldn't that be enough for us to recreate the bounds that they want?

gselzer commented 4 months ago

shouldn't we be able to deal with whatever the user enters? That is: regardless of how they've set up the microscope, if they mark top/bottom/left/right in any way, shouldn't that be enough for us to recreate the bounds that they want?

I'd think so - you can feel free to assign this issue to me!