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
279 stars 138 forks source link

Create pose config Issues #205

Closed carson2stoker closed 1 year ago

carson2stoker commented 1 year ago

Describe the bug Hi, I'm brand new to Simba and trying to create a new project using imported data from Sleap. I have followed the tutorials on Multi_animal_pose.md and Pose_config.md to create my own pose configuration for Bombus Impatiens bumblebees. Once I'm done defining the pose by double clicking each body part on the image, some error messages appear on the command line and my pose config does not show up.

To Reproduce Steps to reproduce the behavior:

  1. Load simba
  2. Click on 'create new project'
  3. go down to animal settings and click 'create pose config' in the drop down box
  4. type in the config details (1 animal, 21 body parts)
  5. give all the body parts names and define them on the image of the animal
  6. click esc on the last image
  7. see error

Expected behavior I expected my newly created pose config to appear in the drop down box next to # config under Animal Settings.

Desktop (please complete the following information):

Logs ``` (base) [u1208563@notchpeak1:~]$ salloc --time=4:00:00 --account=notchpeak-gpu --partition=notchpeak-gpu --nodes=1 --ntasks=1 --mem=60G --gres=gpu:2080ti:1 salloc: Pending job allocation 5071542 salloc: job 5071542 queued and waiting for resources salloc: job 5071542 has been allocated resources salloc: Granted job allocation 5071542 salloc: Waiting for resource configuration salloc: Nodes notch271 are ready for job (base) [u1208563@notch271:~]$ module load anaconda3/2022.05 (base) [u1208563@notch271:~]$ module load simba (/uufs/chpc.utah.edu/sys/installdir/r8/simba/08022022) [u1208563@notch271:~]$ simba Exception in Tkinter callback Traceback (most recent call last): File "/uufs/chpc.utah.edu/sys/installdir/r8/simba/08022022/lib/python3.6/tkinter/__init__.py", line 1705, in __call__ return self.func(*args) File "/uufs/chpc.utah.edu/sys/installdir/r8/simba/08022022/lib/python3.6/site-packages/simba/SimBA.py", line 2913, in self.saveposeConfigbutton = Button(self.scroller,text='Save Pose Config',command=lambda:self.savePoseConfig(self.scroller)) File "/uufs/chpc.utah.edu/sys/installdir/r8/simba/08022022/lib/python3.6/site-packages/simba/SimBA.py", line 2935, in savePoseConfig define_new_pose_configuration(configName, self.noAnimals, noBps, Imagepath, BpNameList, self.noAnimals, animal_id_list) File "/uufs/chpc.utah.edu/sys/installdir/r8/simba/08022022/lib/python3.6/site-packages/simba/define_new_pose_config.py", line 73, in define_new_pose_configuration with open(namePath, 'a') as fd: PermissionError: [Errno 13] Permission denied: '/uufs/chpc.utah.edu/sys/installdir/r8/simba/08022022/lib/python3.6/site-packages/simba/pose_configurations/configuration_names/pose_config_names.csv' ```

It seems like there is a permission error with the cluster. I had them install simba directly on the cluster nodes because it was a pain (some packages are not supported anymore and the setup files very specifically constrain package versions. They suggested you make a yaml file for the conda env. I don't know what all that exactly mean, but that's another issue). Anyway, I don't have access to the direct installation which seems to be what's causing the issue. I couldn't find any previous issues about this couldn't figure it out on my own. Any help will be appreciated. Thanks!

sronilsson commented 1 year ago

Hi @carson2stoker ! Could you post the error msg? It will be a lot easier to diagnose the problem. When you click Esc on the last image, SimBA wants to save your image and your selections inside folders and csv files located where-ever you have SimBA installed. If SimBA isn't installed locally, and lives on somewhere else, it might well be related to some permission to write on that instance where the SimBA code lives.

carson2stoker commented 1 year ago

Yes, I posted the the entire terminal output under Logs on the original post. Just click it to open the box.

sronilsson commented 1 year ago

Ah, sorry I missed it! Yes this is beyond what I know how to fix. When you connect to your instance, you need to do so with read/write permission. This looks like a read error - SimBA want to read the pose_config_names.csv file located in the SimBA packages, but you are not allowed to open it.

carson2stoker commented 1 year ago

Ok, is there anyone else that would know a way to fix this beyond installing elsewhere?