Open keyxuliang opened 5 years ago
Probably a bug since it goes out of its way to compute these and ends up with zero. Training still works regardless.
300W_LP: 0 files 300VW-3D: 217952 files 300W-Testset-3D: 600 files AFLW2000-3D-Reannotated: 1998 files Menpo-3D: 8955 files why it not found images in 300W_LP data set??
and the dataset is exits,the path is right
300W_LP: 0 files 300VW-3D: 217952 files 300W-Testset-3D: 600 files AFLW2000-3D-Reannotated: 1998 files Menpo-3D: 8955 files why it not found images in 300W_LP data set??
Hi @ZhongyuMa
Check that you folder tree looks like this and all landmarks in 300W_LP have .t7 format
|-- 300VW-3D
|-- 300W-Testset-3D
|-- 300W_LP
|-- landmarks
|-- *.t7
|-- AFLW2000-3D-Reannotated
`-- Menpo-3D
Then go to datasets/LS3DW_F.py
and change lines 171-174
a = self.anno[i]
img_path = os.path.join(self.img_folder, self.anno[i].split('_')[0], self.anno[i][:-8] + '.jpg')
img = load_image(img_path)
to
from pathlib import Path
anno_path = Path(self.anno[i])
if 'landmarks' in str(anno_path):
if 'pth' in str(anno_path):
img_path = anno_path.parents[2] / anno_path.parts[-2] / (anno_path.stem + '.jpg')
elif '300W-Testset-3D' in str(anno_path):
img_path = anno_path.parent / (anno_path.stem + '.png')
else:
img_path = anno_path.parent / (anno_path.stem + '.jpg')
img = load_image(str(img_path))
=> loaded train set, 61161 images were found Mean: 0.0000, 0.0000, 0.0000 Std: 0.0000, 0.0000, 0.0000 => Epoch: 1 | LR 0.00025000 Not use all dataset. Why is 0.0000?