Skip to content

Commit

Permalink
Fixed auto annotation, tf annotation and auto segmentation apps (#1409)
Browse files Browse the repository at this point in the history
* fixed code that uses FrameProvider, as the interface has changed

* Update CHANGELOG.md
  • Loading branch information
azhavoro authored Apr 16, 2020
1 parent 3cf0507 commit ca022d7
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
-

### Fixed
-
- Auto annotation, TF annotation and Auto segmentation apps (https://github.com/opencv/cvat/pull/1409)

### Security
-
Expand Down
2 changes: 1 addition & 1 deletion cvat/apps/auto_annotation/image_loader.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ def __init__(self, frame_provider):
self._frame_provider = frame_provider

def __iter__(self):
for frame in self._frame_provider.get_frames(self._frame_provider.Quality.ORIGINAL):
for frame, _ in self._frame_provider.get_frames(self._frame_provider.Quality.ORIGINAL):
yield self._load_image(frame)

def __len__(self):
Expand Down
2 changes: 1 addition & 1 deletion cvat/apps/auto_segmentation/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ class InferenceConfig(coco.CocoConfig):
## RUN OBJECT DETECTION
result = {}
frames = frame_provider.get_frames(frame_provider.Quality.ORIGINAL)
for image_num, image_bytes in enumerate(frames):
for image_num, (image_bytes, _) in enumerate(frames):
job.refresh()
if 'cancel' in job.meta:
del job.meta['cancel']
Expand Down
2 changes: 1 addition & 1 deletion cvat/apps/tf_annotation/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ def _normalize_box(box, w, h):
config.gpu_options.allow_growth=True
sess = tf.Session(graph=detection_graph, config=config)
frames = frame_provider.get_frames(frame_provider.Quality.ORIGINAL)
for image_num, image in enumerate(frames):
for image_num, (image, _) in enumerate(frames):

job.refresh()
if 'cancel' in job.meta:
Expand Down

0 comments on commit ca022d7

Please sign in to comment.