summaryrefslogtreecommitdiff
path: root/utils/dataset.py
diff options
context:
space:
mode:
authorJordan Gong <jordan.gong@protonmail.com>2021-01-23 00:16:58 +0800
committerJordan Gong <jordan.gong@protonmail.com>2021-01-23 00:16:58 +0800
commitf3321b6782aff20df2c029239cc0f8b9a59ffde7 (patch)
treee4b0c952d90e6ffcf255cdc4233496fb5612b886 /utils/dataset.py
parent7b5ff0a8dd2406af74776f31b1e2afabf9fadacd (diff)
Evaluation bug fixes and code review
1. Return full cached clip in evaluation 2. Add multi-iter checkpoints support in evaluation 3. Remove duplicated code while transforming
Diffstat (limited to 'utils/dataset.py')
-rw-r--r--utils/dataset.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/utils/dataset.py b/utils/dataset.py
index cd8b0f1..bbd42c3 100644
--- a/utils/dataset.py
+++ b/utils/dataset.py
@@ -201,6 +201,9 @@ class CASIAB(data.Dataset):
self._cached_clips[clip_name] = clip
else: # Load cache
cached_clip = self._cached_clips[clip_name]
+ # Return full clips while evaluating
+ if not self._is_train:
+ return cached_clip
cached_clip_frame_names \
= self._cached_clips_frame_names[clip_path]
# Index the original clip via sampled frame names