sgoldenlab / simba

SimBA (Simple Behavioral Analysis), a pipeline and GUI for developing supervised behavioral classifiers
https://simba-uw-tf-dev.readthedocs.io/
GNU General Public License v3.0
272 stars 137 forks source link

Error during user defined Project Configuration for custom multi-animal tracking #346

Open drish-soneja opened 4 months ago

drish-soneja commented 4 months ago

Describe the bug In the define pose window: during assigning body parts to individual animals on the image, the screen has the selected image and there seem to be buttons above the image but they are not visible. After assigning the body parts to the animals the define pose window closes and the project configuration page still has different tabs but they are all blank. The main window shows that user defined pose configuration has been created. But since the rest of the tabs on the project configuration page are blank I cannot finish creating the project.

To Reproduce Steps to reproduce the behavior:

  1. Go to File -> create new project
  2. select multi animal tracking and custom tracking (2 animals and 6 body parts per animal)
  3. assign user defined nodes to the selected image
  4. See error

Screenshots Terminal: Pasted image 3

Define pose page during node assignment: Pasted image

Blank project configuration page after node assignment Pasted image 1

Main simba window after node assignment: Pasted image 2

Desktop (please complete the following information):

sronilsson commented 4 months ago

Thanks for reporting @drish-soneja - can you upgrade to 1.87.1 with pip install simba-uw-tf-dev --upgrade and let me know how it looks?

If that does not solve it, how does it look if you install 1.87.1 in a new conda environment, or run pip uninstall simba-uw-tf-dev and then pip install simba-uw-tf-dev ?

drish-soneja commented 3 months ago

hi @sronilsson thank you for your help, the update fixed the problem I was having!

I did run into another issue when I was trying to annotate my video. None of the key shortcuts were working to navigate the video. Pasted image 1 Let me know if I should open a new issue for this.

sronilsson commented 3 months ago

Thanks for letting me know @drish-soneja, no need to open another issue. I will see if I can replicate it and get back to you

sronilsson commented 3 months ago

@drish-soneja I tried on MacOS and in Ubuntu and unfortunately I can't replicate the error and I don't have a machine running fedora around. The keyboard bindings are controlled though opencv, perhaps it is a opencv version issue - which version of opencv do you have in your simba conda environment? This is what I have.

image

drish-soneja commented 3 months ago

I have the same version as you do. Do you think I should update opencv? Pasted image 2

sronilsson commented 3 months ago

No that looks OK.. one more question. Which version of tkiinter does your environment have?

image
drish-soneja commented 3 months ago

I have the same version as you for tkinter too Pasted image 3

drish-soneja commented 3 months ago

the keybinds worked for labelling the body parts when I was defining the pose. I was able the use the x and c keys to change the frame and continue. So I think it might be something specific to this window?

sronilsson commented 3 months ago

Yeah - sorry for mentioning opencv thing earlier, it's not actually opencv that binds the keys while labelling, its through tkinter right here in the code. The x and z keys used earlier, is through opencv.

My suspicion, as I don't see this error on mac or ubuntu, is that it has to do with with the tkinter version running on fedora. One more thing you could help me try to see if this is the cause: you could try to run simba in python3.9 or python3.10 conda environment (I know there will be some warnings but it should run), that gives you a different tkinter version automatically through the python3.9 or python 3.10 standard library, and you could see if the error persist? Also make sur eyou don't have caps lock pressed.

drish-soneja commented 3 months ago

For python = 3.6

I realised that the frame navigation keybinds (ctl+a, right, left, etc) are working, its only the video navigation(p, o, etc) that wasnt working. So I can use the frame navigation keybinds to go through my video.

Also when I try to draw an ROI this is what the screen looks like: Pasted image 4 I'm not able to see frames from my videos but the video information is dispayed in the ROI settings window.

For python = 3.9 I got a tkinter error when trying to load the project. Pasted image

also thank you so much for all your help!

sronilsson commented 3 months ago

Thank you, super helpful - one question about the ROI issue before I dig in those issues: do you see any error message in the Linux terminal when you "top level not responding" pop up?