Open su850131 opened 11 months ago
Hi @su850131, you are right that this repository needs a simple demo like this. However it will require some time to do something nice and I'm very busy right now. I will provide a demo in late November when I will have more time. In the meantime, you can have a look at issue #27 for tips to achieve this.
OK, I will look at issue #27, thank you for your help. I’m looking forward to your demo!
Hi, thank you for your great job
Honestly, I am also waiting for your simple demo.
When I run your mentioned example in the main/torchreid/tools/feature_extractor.py
file
Examples::
from torchreid.utils import FeatureExtractor
extractor = FeatureExtractor(
model_name='osnet_x1_0',
model_path='a/b/c/model.pth.tar',
device='cuda'
)
image_list = [
'a/b/c/image001.jpg',
'a/b/c/image002.jpg',
'a/b/c/image003.jpg',
'a/b/c/image004.jpg',
'a/b/c/image005.jpg'
]
features = extractor(image_list)
print(features.shape) # output (5, 512)
I got this error:
ImportError: cannot import name 'FeatureExtractor' from 'torchreid.utils'
Hi, thank you for your great job Honestly, I am also waiting for your simple demo. When I run your mentioned example in the
main/torchreid/tools/feature_extractor.py
fileExamples:: from torchreid.utils import FeatureExtractor extractor = FeatureExtractor( model_name='osnet_x1_0', model_path='a/b/c/model.pth.tar', device='cuda' ) image_list = [ 'a/b/c/image001.jpg', 'a/b/c/image002.jpg', 'a/b/c/image003.jpg', 'a/b/c/image004.jpg', 'a/b/c/image005.jpg' ] features = extractor(image_list) print(features.shape) # output (5, 512)
I got this error:
ImportError: cannot import name 'FeatureExtractor' from 'torchreid.utils'
Its probably because there is no such module in torchreid.utils, try this instead, from torchreid.tools.feature_extractor import FeatureExtractor
Hi, thank you for your great job Honestly, I am also waiting for your simple demo. When I run your mentioned example in the
main/torchreid/tools/feature_extractor.py
fileExamples:: from torchreid.utils import FeatureExtractor extractor = FeatureExtractor( model_name='osnet_x1_0', model_path='a/b/c/model.pth.tar', device='cuda' ) image_list = [ 'a/b/c/image001.jpg', 'a/b/c/image002.jpg', 'a/b/c/image003.jpg', 'a/b/c/image004.jpg', 'a/b/c/image005.jpg' ] features = extractor(image_list) print(features.shape) # output (5, 512)
I got this error:
ImportError: cannot import name 'FeatureExtractor' from 'torchreid.utils'
Its probably because there is no such module in torchreid.utils, try this instead, from torchreid.tools.feature_extractor import FeatureExtractor
You can import "torchreid.reid.utils" I found it in env site-packages, have this structure torchreid>reid>model,utils etc.
Hi, Can you provide a simple demo? input 2 image and 2 mask, output all distances. Thank you!