(self, transform, data_split)
| 16 | |
| 17 | class EHF(HumanDataset): |
| 18 | def __init__(self, transform, data_split): |
| 19 | super(EHF, self).__init__(transform, data_split) |
| 20 | |
| 21 | self.transform = transform |
| 22 | self.data_split = data_split |
| 23 | self.save_idx = 0 |
| 24 | # self.cam_param = {'R': [-2.98747896, 0.01172457, -0.05704687]} |
| 25 | # self.cam_param['R'], _ = cv2.Rodrigues(np.array(self.cam_param['R'])) |
| 26 | self.cam_param = {} |
| 27 | self.img_dir = 'data/data_weichen/ehf' |
| 28 | self.img_shape = [1200, 1600] |
| 29 | |
| 30 | self.annot_path = 'data_tmp/multihuman_data/ehf_val_230908_100.npz' |
| 31 | self.annot_path_cache = 'data_tmp/cache/ehf_val_cache_230908_100.npz' |
| 32 | |
| 33 | if self.use_cache and osp.isfile(self.annot_path_cache): |
| 34 | print(f'[{self.__class__.__name__}] loading cache from {self.annot_path_cache}') |
| 35 | self.datalist = self.load_cache(self.annot_path_cache) |
| 36 | else: |
| 37 | if self.use_cache: |
| 38 | print(f'[{self.__class__.__name__}] Cache not found, generating cache...') |
| 39 | self.datalist = self.load_data( |
| 40 | train_sample_interval=getattr(cfg, f'{self.__class__.__name__}_train_sample_interval', 1)) |
| 41 | if self.use_cache: |
| 42 | self.save_cache(self.annot_path_cache, self.datalist) |
| 43 | |
| 44 | |
| 45 | def evaluate(self, outs, cur_sample_idx): |
nothing calls this directly
no test coverage detected