MaskTextSpotter icon indicating copy to clipboard operation
MaskTextSpotter copied to clipboard

Evaluation: Calculated!{"precision": 0, "recall": 0.0, "hmean": 0, "AP": 0}

Open HHeracles opened this issue 3 years ago • 4 comments

Hello @MhLiao ,when I have run the command “cd evaluation/icdar2015/e2e/” and “python script.py”,I used the downloaded model “model_finetune.pth” and the icdar2015.But the output is ”Calculated!{"precision": 0, "recall": 0.0, "hmean": 0, "AP": 0}“. I don't know why. I looked at the code and found that folder ”/outputs/finetune/inference/icdar_2015_test/model_finetune_1600_results/“ was missing.How do I get folder" /outputs/finetune/inference/icdar_2015_test/model_finetune_1600_results/"?

HHeracles avatar Sep 02 '20 08:09 HHeracles

@HHeracles You should run the testing and then you will have the results directory. For the evaluation, you should set the result directory as your own.

MhLiao avatar Sep 07 '20 01:09 MhLiao

@MhLiao Thanks for your kind reply. I got your points and have solved the problem .But then I have the following three questions.

First,I set parameters “TEST: ("icdar_2015_test",),DATALOADER:(NUM_WORKERS: 0)”,and the other parameters are the default values that you provide.Then I do the following: (1),sh test.sh; (2), cd evaluation/icdar2015/e2e/; (3), python script.py. but I get the result is "Calculated!{"precision": 0.8910947249007374, "recall": 0.7563793933558016, "hmean": 0.8182291666666666, "AP": 0} ".The result is right?

Second,What should I do if I just want to get the detection results, such as the data in Table 1 in your paper? Do I need to modify the ROI_MASK_HEAD parameter “MASK_ON: false” or other parameters ,then to retrain the model?

Third,when I have run the command "python3 -m torch.distributed.launch --nproc_per_node=8 tools/train_net.py --config-file configs/finetune.yaml" with one GPU ,I got the error "File "/MaskTextSpotter/maskrcnn_benchmark/engine/trainer.py", line 64, in targets = [target.to(device) for target in targets] AttributeError: 'NoneType' object has no attribute 'to'"Do I need to change the code in the data load section to solve this problem?

HHeracles avatar Sep 08 '20 05:09 HHeracles

@MhLiao Thank you for your reply. I will try again as you suggest.

HHeracles avatar Sep 24 '20 08:09 HHeracles

@MhLiao Thanks for your kind reply. I got your points and have solved the problem .But then I have the following three questions.

First,I set parameters “TEST: ("icdar_2015_test",),DATALOADER:(NUM_WORKERS: 0)”,and the other parameters are the default values that you provide.Then I do the following: (1),sh test.sh; (2), cd evaluation/icdar2015/e2e/; (3), python script.py. but I get the result is "Calculated!{"precision": 0.8910947249007374, "recall": 0.7563793933558016, "hmean": 0.8182291666666666, "AP": 0} ".The result is right?

Second,What should I do if I just want to get the detection results, such as the data in Table 1 in your paper? Do I need to modify the ROI_MASK_HEAD parameter “MASK_ON: false” or other parameters ,then to retrain the model?

Third,when I have run the command "python3 -m torch.distributed.launch --nproc_per_node=8 tools/train_net.py --config-file configs/finetune.yaml" with one GPU ,I got the error "File "/MaskTextSpotter/maskrcnn_benchmark/engine/trainer.py", line 64, in targets = [target.to(device) for target in targets] AttributeError: 'NoneType' object has no attribute 'to'"Do I need to change the code in the data load section to solve this problem?

Hello, about your second question, I also want to get the detection results and evaluate them. What should I do? Can you help me? Thank you

gtb1551050818 avatar Jan 14 '22 02:01 gtb1551050818