8000 ZeroDivisionError when attempting to download annotations · Issue #1437 · cvat-ai/cvat · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
ZeroDivisionError when attempting to download annotations #1437
Closed
@akarimbux

Description

@akarimbux

My actions before raising this issue

I searched both existing issues and gitter for this error and couldn't find a reference

Current Behaviour

XML that causes this issue attached.

I am running into an issue with the TASK endpoint where annotations that have loaded successfully raise an error when I attempt to download them. The created task has a segment size of 1500 frames and 5 frames of overlap. This generates 2 jobs against which the attached annotation xml file is loaded.

Without making any changes to the annotations, attempting to download them, throws the following error:

`
2020-04-20 17:56:51,915 DEBG 'rqworker_default_1' stderr output:
17:56:51 cvat.apps.engine.utils.InterpreterError: AssertionError
Traceback (most recent call last):
File "/home/django/cvat/apps/engine/utils.py", line 45, in execute_python_code
exec(source_code, global_vars, local_vars)
File "", line 1, in
File "", line 393, in dump_as_cvat_interpolation
File "/home/django/cvat/apps/annotation/annotation.py", line 341, in tracks
tracked_shapes = TrackManager.get_interpolated_shapes(track, 0, self._db_task.size)
File "/home/django/cvat/apps/engine/data_manager.py", line 360, in get_interpolated_shapes
assert shape["frame"] > curr_frame
AssertionError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/rq/worker.py", line 812, in perform_job
rv = job.perform()
File "/usr/local/lib/python3.5/dist-packages/rq/job.py", line 588, in perform
self._result = self._execute()
File "/usr/local/lib/python3.5/dist-packages/rq/job.py", line 594, in _execute
return self.func(*self.args, **self.kwargs)
File "/home/django/cvat/apps/engine/annotation.py", line 135, in dump_task_data
annotation.dump(filename, dumper, scheme, host)
File "/home/django/cvat/apps/engine/annotation.py", line 740, in dump
execute_python_code("{}(file_object, annotations)".format(dumper.handler), global_vars)
File "/home/django/cvat/apps/engine/utils.py", line 54, in execute_python_code
raise InterpreterError("{}".format(error_class))
cvat.apps.engine.utils.InterpreterError: AssertionError
Traceback (most recent call last):
File "/home/django/cvat/apps/engine/utils.py", line 45, in execute_python_code
exec(source_code, global_vars, local_vars)
File "", line 1, in
File "", line 393, in dump_as_cvat_interpolation
File "/home/django/cvat/apps/annotation/annotation.py", line 341, in tracks
tracked_shapes = TrackManager.get_interpolated_shapes(track, 0, self._db_task.size)
File "/home/django/cvat/apps/engine/data_manager.py", line 360, in get_interpolated_shapes
assert shape["frame"] > curr_frame
AssertionError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/rq/worker.py", line 812, in perform_job
rv = job.perform()
File "/usr/local/lib/python3.5/dist-packages/rq/job.py", line 588, in perform
self._result = self._execute()
File "/usr/local/lib/python3.5/dist-packages/rq/job.py", line 594, in _execute
return self.func(*self.args, **self.kwargs)
File "/home/django/cvat/apps/engine/annotation.py", line 135, in dump_task_data
annotation.dump(filename, dumper, scheme, host)
File "/home/django/cvat/apps/engine/annotation.py", line 740, in dump
execute_python_code("{}(file_object, annotations)".format(dumper.handler), global_vars)
File "/home/django/cvat/apps/engine/utils.py", line 54, in execute_python_code
raise InterpreterError("{}".format(error_class))
cvat.apps.engine.utils.InterpreterError: AssertionError
`

Sometimes a different error is thrown using the same set of actions above:
ZeroDivisionError: division by zero Traceback (most recent call last): File "/usr/local/lib/python3.5/dist-packages/rq/worker.py", line 812, in perform_job rv = job.perform() File "/usr/local/lib/python3.5/dist-packages/rq/job.py", line 588, in perform self._result = self._execute() File "/usr/local/lib/python3.5/dist-packages/rq/job.py", line 594, in _execute return self.func(*self.args, **self.kwargs) File "/usr/lib/python3.5/contextlib.py", line 30, in inner return func(*args, **kwds) File "/home/django/cvat/apps/engine/annotation.py", line 112, in load_task_data annotation.upload(filename, loader) File "/home/django/cvat/apps/engine/annotation.py", line 761, in upload self.create(annotation_importer.data.serialize()) File "/home/django/cvat/apps/engine/annotation.py", line 697, in create self._patch_data(data, PatchAction.CREATE) File "/home/django/cvat/apps/engine/annotation.py", line 687, in _patch_data self._merge_data(_data, jobs[jid]["start"], self.db_task.overlap) File "/home/django/cvat/apps/engine/annotation.py", line 691, in _merge_data data_manager.merge(data, start_frame, overlap) File "/home/django/cvat/apps/engine/data_manager.py", line 22, in merge tracks.merge(data.tracks, start_frame, overlap) File "/home/django/cvat/apps/engine/data_manager.py", line 107, in merge int_obj, old_obj, start_frame, overlap) File "/home/django/cvat/apps/engine/data_manager.py", line 278, in _calc_objects_similarity return 1 - error / count ZeroDivisionError: division by zero

Your Environment

  • Git hash commit (git log -1): feebec2
  • Docker version docker version (e.g. Docker 17.0.05): 19.03.8
  • Are you using Docker Swarm or Kubernetes? No
  • Operating System and version (e.g. Linux, Windows, MacOS): Ubuntu

Next steps

You may join our Gitter channel for community support.

bad.xml.txt

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0