8000 Providing example GUIs for users to build upon · Issue #38 · open-ephys/miniscope-docs · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Providing example GUIs for users to build upon #38

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

Open
ChucklesOnGitHub opened this issue May 15, 2025 · 5 comments
Open

Providing example GUIs for users to build upon #38

ChucklesOnGitHub opened this issue May 15, 2025 · 5 comments
Assignees
Milestone

Comments

@ChucklesOnGitHub
Copy link
Member

The approach here would be three-fold:

  1. A standard layout that shows all the datastreams and the control panel, with some additional visualization processing / quantification that will be useful for most users. This would be useful in the context of acquisition: seeing the data flowing in and adjusting parameters. A rough mockup is below. It includes the image, imu and digital input data representations, and df/f, saturation and pixel intensity.

Image

  1. Modular examples of additional processing and how to edit the standard layout to include them. These can be miniscope specific, such as ROI intensity dynamics, a maximum intensity projection to identify cells, a heading calculation from the quaternion data, etc. Additionally, we could show some other typical experimental data viz such as a behavioral camera view, centroid tracking, 2D histogram of space occupation, etc. This is to inspire users to make their own custom representations according to their experimental needs.

  2. A proper GUI would have to include record control and file management. Not only a Record button on the UI, but also settings such as path, encoding, recording length, etc. The logic to make this would define a folder structure that therefore can provide standarization for miniscope data acquired in Bonsai. In turn, having a standardized data structure and format makes it easier to interface with open sharable data analysis pipelines.

These thoughts are obviously heavily inspired by the existing functionality of the Miniscope-DAQ-qt soft from the UCLA Miniscope Team and the OEGUI modularity, and pushed forward by user requests. Once we have a prototype, we should ask for feedback and contributions. The scope has to be clear because, even with all of Bonsai's interoperability and flexibility, I'm not sure making layouts will make for a true bespoke GUI application. Such an application additionally needs to log changes in parameters and report meaningful errors for troubleshooting.

@cjsha
Copy link
Member
cjsha commented May 20, 2025

Here's some progress:

Image

miniscope-gui.zip

@ChucklesOnGitHub
Copy link
Member Author

This is awesome! Some comments:

  • could we have two numbers, one for elapsed acquisition time (start of wf) as well as one for elapsed recording time?
  • make sure all data is getting timestamped
  • do ppl want property values to be persistent or initialize to a set value when wf is opened
  • add duration units ("seconds") to the recording duration
  • fix the y value of the Input Trigger graph
  • see how to handle exception of not having a suffix and hitting record without overwrite

More potential additions if useful:

  • look into example workflows and see if the gui could use buttons to control things
    • commutator functionality idk enable/disable
    • a checkbox for triggering recordings based on Input trigger = TRUE? Under the RecordingDuration checkbox.
  • max pixel value projection over many frames to be able to count cells (in a radio button)

Out of original scope but very useful:

  • have the ability to supply a filename and playback videos

Iteration 2: how can we potentially include camera data?

@cjsha
Copy link
Member
cjsha commented May 23, 2025

These things are implemented:

  • could we have two numbers, one for elapsed acquisition time (start of wf) as well as one for elapsed recording time?
  • make sure all data is getting timestamped
  • add duration units ("seconds") to the recording duration
  • a checkbox for triggering recordings based on Input trigger = TRUE? Under the RecordingDuration checkbox.

These things I'm unsure about:

  • do ppl want property values to be persistent or initialize to a set value when wf is opened
    • I think values should persist, I think that makes the GUI easier to use.
  • fix the y value of the Input Trigger graph
    • I'm not sure what you mean by this, but people have the capacity to right-click the graph and change zoom or whatever

For later:

  • see how to handle exception of not having a suffix and hitting record without overwrite
    • I'm not immediately sure the best way to handle this
  • button for commutator functionality idk enable/disable
  • have the ability to supply a filename and playback videos
  • max pixel value projection over many frames to be able to count cells (in a radio button)

Other information:

I made a change to save trigger data as a CSV using the same pattern that's used to save video data. I noticed the CSV file is created even if no data is written to it

miniscope-gui.zip

Image

@ChucklesOnGitHub
Copy link
Member Author

This is awesome, it's so great to see it taking shape, thank you, Cris. Some more asks after reviewing the docs:

  • have the "Reecord On Trigger" button also change the LedRespectsTrigger property to True, and back to False again when the button is deselected, because that is how most ppl will intend the recording trigger to be used (LED is on when trigger signal is high and thus recording files).
  • have the recorded file increment on each hardware trigger instead of appending the frames to the same file
  • expose the FourCC propery in the properties pane?
  • fix the y value of the Input Trigger graph -> here I meant to say we could fix ylim at, say (0,1.1) because the values are going to be either 0 or 1 and otherwise the graph initializes as -1 and 1 and then jumps. Just cosmetic. I was unable to change the ylim during acquisition, only by editing the workflow normally.

@cjsha
Copy link
Member
cjsha commented May 27, 2025

have the "Reecord On Trigger" button also change the LedRespectsTrigger property to True, and back to False again when the button is deselected, because that is how most ppl will intend the recording trigger to be used (LED is on when trigger signal is high and thus recording files).

It makes sense that that's how users are expected to user it. But I'm not sure we want UI elements to have side-effects like this. I think for now it's ok that they have to manually set it, and we can come back to this on the next GUI revision (when we get feedback, add the bobblehead visualizer, etc.)

have the recorded file increment on each hardware trigger instead of appending the frames to the same file

That seems important. I'm going to implement this and push the corresponding change in PR #41 (commit: 4dbbc56)

expose the FourCC propery in the properties pane?

Not sure we should expose this to user. We want a simplified GUI. But I will make it easier to change in the workflow, and add a note about how to change it in the tutorial

fix the y value of the Input Trigger graph -> here I meant to say we could fix ylim at, say (0,1.1) because the values are going to be either 0 or 1 and otherwise the graph initializes as -1 and 1 and then jumps. Just cosmetic. I was unable to change the ylim during acquisition, only by editing the workflow normally.

Oh you're right, the visualizer only allows limit changes in the standalone visualizer, not the one embedded in the GUI. Not sure how to do this, I'm leaving it for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants
0