Open alaa-shubbak opened 1 year ago
until now i did not understand why making this mmpretrain repository and add mmselfsup to it . it is more complicate to get it and make me confused.
why not work separately on the mmselfsup? and what is the benefit of that? even more there is no colab example or complete example explain what is going on here with mmpretrain like what have been mentioned in mmselfsup.
should i install mmselfsup with mmpretrain so i can train my selfsup model, or just train it with mmpretrain library?
For self-supervised leanrnig algorithms, there is no mode for 'predict'. Besides, to train your selfsup model, you could just train it with mmpretrain library.
For self-supervised leanrnig algorithms, there is no mode for 'predict'. Besides, to train your selfsup model, you could just train it with mmpretrain library.
thank you for response. I did so . I try to train my selfsup model using mmpretrain as mentioned above , but I got such error
RuntimeError: Invalid mode "predict".
so i was so confused ,as it is my first time to see such error in open-mmlab
could you please help me in solving such error?
here is the dataset config i modified :
is it forbidden to have the test,val dataloader, pipeline and evaluator within training the selfsup models?
looking forward to have an answer from your side.
I still need to open this issue again , but for another task as bellow :
I try to run inference over my self-supervised trained model. so i used this info and commands in this doc
unfortunately , I got this error again :
raise RuntimeError(f'Invalid mode "{mode}".')
RuntimeError: Invalid mode "predict".
which means that inference does not working with mmselfsupervised model , although i modified my config to have the test_pipeline and the val_dataloader
according to this , can some one please explain to me how to test my pretrained self-supervised model over my part of the data (images without labels) and get the classes ? I don't need to use another downstream tasks such as detection and segmenation , i only need the classification.
any help please ?
here is the full error log after running the last command of >>> result = inferencer(image)[0]
Inference ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Traceback (most recent call last):
File "
Branch
main branch (mmpretrain version)
Describe the bug
i try to run the training of a model of densecl on my custom dataset i run this command on 1 gpu system
python tools/train.py configs/densecl/densecl_resnet50_8xb32-coslr-200e_ACID.py --work-dir train_dir/densecl_resnet50_ACID/
the model started the training ,and reached to 1st iterative values ,saved the epoch results of 10 then gave me the following error message:
which is the
RuntimeError: Invalid mode "predict".
i don't have any idea about such error , could you please help me?Environment
after running /getting the environment info , i got this `` {'sys.platform': 'linux', 'Python': '3.8.11 (default, Jul 13 2021, 14:00:03) [GCC 4.8.5 20150623 (Red ' 'Hat 4.8.5-44)]', 'CUDA available': True, 'numpy_random_seed': 2147483648, 'GPU 0': 'Tesla V100-SXM2-32GB', 'CUDA_HOME': '/usr/local/cuda', 'NVCC': 'Cuda compilation tools, release 12.1, V12.1.105', 'GCC': 'gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-44)', 'PyTorch': '2.0.0+cu117', 'TorchVision': '0.15.1+cu117', 'OpenCV': '4.7.0', 'MMEngine': '0.7.3', 'MMCV': '2.0.0', 'MMPreTrain': '1.0.0rc7+e80418a'}
``
Other information
i did the modification on the my new dataset file , which is under base/dataset
also i add more info in the config file to ensure that the iteartive will be 10 instead of 100 in the original densecl as my dataset is smaller compared to the imagenet dataset.
i used the original imagenet_bs32_mocov2.py
but add more info /dir for test and val dataloader , pipleline ,cfg and evaluator .