Fixed auto annotation, tf annotation and auto segmentation apps (#1409)

* fixed code that uses FrameProvider, as the interface has changed

* Update CHANGELOG.md
main
Andrey Zhavoronkov 6 years ago committed by GitHub
parent 3cf0507e52
commit ca022d732d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -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
-

@ -11,7 +11,7 @@ class ImageLoader():
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):

@ -82,7 +82,7 @@ def run_tensorflow_auto_segmentation(frame_provider, labels_mapping, treshold):
## 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']

@ -117,7 +117,7 @@ def run_tensorflow_annotation(frame_provider, labels_mapping, treshold):
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:

Loading…
Cancel
Save