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

assert failed when training second epoch #11

Open
xuduo35 opened this issue Feb 14, 2021 · 2 comments
Open

assert failed when training second epoch #11

xuduo35 opened this issue Feb 14, 2021 · 2 comments

Comments

@xuduo35
Copy link

xuduo35 commented Feb 14, 2021

How can I fix this?

Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/autoalbument/cli/search.py", line 41, in main
faa_searcher.search()
File "/usr/local/lib/python3.8/dist-packages/autoalbument/faster_autoaugment/search.py", line 354, in search
self.save()
File "/usr/local/lib/python3.8/dist-packages/autoalbument/faster_autoaugment/search.py", line 312, in save
self.save_policy()
File "/usr/local/lib/python3.8/dist-packages/autoalbument/faster_autoaugment/search.py", line 274, in save_policy
transform = self.models["policy"].create_transform(
File "/usr/local/lib/python3.8/dist-packages/autoalbument/faster_autoaugment/policy.py", line 195, in create_transform
OneOf([sp.create_transform(input_dtype, p=sub_policy_p) for sp in self.sub_policies], p=1),
File "/usr/local/lib/python3.8/dist-packages/autoalbument/faster_autoaugment/policy.py", line 195, in
OneOf([sp.create_transform(input_dtype, p=sub_policy_p) for sp in self.sub_policies], p=1),
File "/usr/local/lib/python3.8/dist-packages/autoalbument/faster_autoaugment/policy.py", line 88, in create_transform
return A.Sequential([stage.create_transform(input_dtype) for stage in self.stages], p=p)
File "/usr/local/lib/python3.8/dist-packages/autoalbument/faster_autoaugment/policy.py", line 88, in
return A.Sequential([stage.create_transform(input_dtype) for stage in self.stages], p=p)
File "/usr/local/lib/python3.8/dist-packages/autoalbument/faster_autoaugment/policy.py", line 63, in create_transform
assert sum(true_probabilities) <= 1.0
AssertionError

@creafz
Copy link
Contributor

creafz commented Feb 16, 2021

Hey, @xuduo35

I guess that the assertion was triggered because of rounding errors for float probability values. I have released a new version of AutoAlbument (==0.3.1) that will show a RuntimeWarning instead of triggering an assertion in case of incorrect probability values. Generally speaking, probability values slightly above 1.0 should not affect augmentations' performance, but if after the update you will get a RuntimeWarning for incorrect probability values, please report the issue.

@xuduo35
Copy link
Author

xuduo35 commented Feb 17, 2021

Thanks! I'll try later.

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