Skip to content
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

Error in labo_train.sh #1

Closed
Susmit-A opened this issue Jun 7, 2023 · 4 comments
Closed

Error in labo_train.sh #1

Susmit-A opened this issue Jun 7, 2023 · 4 comments

Comments

@Susmit-A
Copy link

Susmit-A commented Jun 7, 2023

I get the following error:

main.py: error: argument --func: expected one argument

Examining the script and the code, the value of $asso_opt_main is undefined in labo_train.sh and the eval() function in main.py is also undefined.

@YueYANG1996
Copy link
Owner

asso_opt_main is the function name and doesn't require any value.
eval() is the built-in function of python.

@Susmit-A
Copy link
Author

Susmit-A commented Jun 8, 2023

Thanks for the response, had to remove the "$" symbol before asso_opt_main in the train bash script.

I'm also getting the following error when running in line 163 of submodular_select:
"ValueError: X cannot contain negative values or must be entirely negative values."
This is for the features in path "exp/asso_opt/CIFAR10/CIFAR10_allshot_fac/concepts_feat_ViT-L-14.pth"

@YueYANG1996
Copy link
Owner

YueYANG1996 commented Jun 8, 2023

I have this error before and I fixed it by modifying the source file of the apricot package. You can change the line 202 of the base.py in the error message to make it can take in negative values.

@Susmit-A
Copy link
Author

Susmit-A commented Jun 9, 2023

Thank you for the prompt resolution!

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