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

Custom_Dataset example - AttributeError: 'Namespace' object has no attribute 'amp' #123

Closed
alysiayx opened this issue Jul 3, 2023 · 3 comments
Labels
bug Something isn't working Stale

Comments

@alysiayx
Copy link

alysiayx commented Jul 3, 2023

I tried to run the example Custom_Dataset.ipynb (https://colab.research.google.com/drive/1zbswPm1sM8j0fndUQOeqX2HADdYq-wOw) but an error raised:

in FixMatch.init(self, args, net_builder, tb_log, logger)
33 def init(self, args, net_builder, tb_log=None, logger=None):
---> 34 super().init(args, net_builder, tb_log, logger)
35 # fixmatch specified arguments
36 self.init(T=args.T, p_cutoff=args.p_cutoff, hard_label=args.hard_label)
...
---> 54 self.use_amp = args.amp
55 self.clip_grad = args.clip_grad
56 self.save_name = args.save_name

AttributeError: 'Namespace' object has no attribute 'amp'

This bug should be fixed before but I am pretty sure that I've downloaded the latest version of the package.

Can anyone help with this error?

@alysiayx alysiayx changed the title FixMatch - AttributeError: 'Namespace' object has no attribute 'amp' Custom_Dataset example - AttributeError: 'Namespace' object has no attribute 'amp' Jul 3, 2023
@zhaisilong
Copy link

try this self.use_amp = args.use_amp

Hhhhhhao added a commit that referenced this issue Jul 20, 2023
@Hhhhhhao Hhhhhhao added the bug Something isn't working label Jul 20, 2023
Hhhhhhao added a commit that referenced this issue Jul 20, 2023
* [Update] resolve requirements.txt conflicts

* [Fix] Fix mean teacher bug in #102

* [Fix] Fix DebiasPL bug

* [Fix] Fix potential sample data bug in #119

* [Update] Add auto issue/pr closer

* [Update] Update requirements.txt

* [Fix] Fix bug in #74

* [Fix] Fix amp lighting bug in #123

* [Fix] Fix notebook bugs

* [Update] release semilearn 0.3.1
@github-actions
Copy link

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

@github-actions github-actions bot added the Stale label Aug 20, 2023
@github-actions
Copy link

This issue was closed because it has been stalled for 5 days with no activity.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Aug 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Stale
Projects
None yet
Development

No branches or pull requests

3 participants