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

can't iterate #1

Open
Love-Studyyy opened this issue Jun 16, 2021 · 2 comments
Open

can't iterate #1

Love-Studyyy opened this issue Jun 16, 2021 · 2 comments

Comments

@Love-Studyyy
Copy link

Hi, can you help me please?

multiprocessing.pool.RemoteTraceback:
"""
Traceback (most recent call last):
File "D:\Segment\envs\trans\lib\multiprocessing\pool.py", line 119, in worker
result = (True, func(*args, **kwds))
File "d:\labels-master\png_to_json.py", line 149, in image_to_json
segmentations,areas,bboxs = create_sub_mask_annotation(mask, image_id, category_id, annotation_id, is_crowd)
File "d:\labels-master\png_to_json.py", line 53, in create_sub_mask_annotation
contour = np.vstack(contour).squeeze()
File "<array_function internals>", line 6, in vstack
TypeError: dispatcher for array_function did not return an iterable
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "d:/labels-master/png_to_json.py", line 251, in
for _ in tqdm.tqdm(pool.imap( image_to_json_partial, range(l)), total=l):
File "D:\Segment\envs\trans\lib\site-packages\tqdm\std.py", line 1178, in iter
for obj in iterable:
File "D:\Segment\envs\trans\lib\multiprocessing\pool.py", line 736, in next
raise value
TypeError: dispatcher for array_function did not return an iterable

-----How can I solve it?

@sudecki30
Copy link
Owner

Hi, I have correct the code to work with actual package version

@Love-Studyyy
Copy link
Author

It is successful!!!!!!!!!
My gratitude to you for all you have done!!!!!!!!!

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