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
290 stars 141 forks source link

Error in terminal while training models. #198

Closed n-zeng closed 2 years ago

n-zeng commented 2 years ago

When I train multiple models or a single model, I get an error in terminal. If training multiple models, I get an attribute error; if training a single model, I get a missing file error from a file that is indeed not there.

To Reproduce Steps to reproduce the behavior:

  1. Get up to train machine model
  2. Input machine model settings for either global or multiple
  3. Press either "train" button

Expected behavior The training starts, and runs smoothly through.

Screenshots

Screen Shot 2022-07-13 at 11 58 35 AM

Desktop (please complete the following information):

sronilsson commented 2 years ago

Hi @n-zeng - thanks for reporting, I will look to insert a better error msg.

SimBA is checking the undersample setting for the specific model, if it is None or Random undersample. However, it encounters a float value (e.g., 0.8) so you see this error. Could it be that the config for this specific model has the undersample setting and under sample ratio mixed up? The ratio should be a float value while the setting entry box should have a string.

P.S you can open up the configs for the specific models in the project_folder\configs directory and check and change the values without going through the GUI.

n-zeng commented 2 years ago

Hi @n-zeng - thanks for reporting, I will look to insert a better error msg.

SimBA is checking the undersample setting for the specific model, if it is None or Random undersample. However, it encounters a float value (e.g., 0.8) so you see this error. Could it be that the config for this specific model has the undersample setting and under sample ratio mixed up? The ratio should be a float value while the setting entry box should have a string.

P.S you can open up the configs for the specific models in the project_folder\configs directory and check and change the values without going through the GUI.

Great, thanks a lot! I had undersample setting set to NaN instead of 'None', and that was the root of the issue.