ScanSSD icon indicating copy to clipboard operation
ScanSSD copied to clipboard

How could I detect formula on my own image using pre-trained weight AMATH...pth ?

Open ainouch opened this issue 3 years ago • 1 comments

Hello! I've tried to run ' detect.py' in conda virtual env in which I've installed PyTorch CPU version. It shows me the following error:

ScanSSD-master>python detect.py Traceback (most recent call last): File "detect.py", line 156, in md = MathDetector('AMATH512_e1GTDB.pth', ArgStub()) File "detect.py", line 96, in init net = build_ssd(args, 'test', config.exp_cfg[args.cfg], 0, args.model_type, 2) File "C:\Users\UM6P\Desktop\Anass D4-R projects\anass_formulas_recog_project\ScanSSD-master\ScanSSD-master\ssd.py", line 218, in build_ssd return SSD(args, phase, cfg, size, base_, extras_, head_, num_classes, gpu_id) File "C:\Users\UM6P\Desktop\Anass D4-R projects\anass_formulas_recog_project\ScanSSD-master\ScanSSD-master\ssd.py", line 38, in init self.priors.to(gpu_id) File "C:\Users\UM6P\anaconda3\envs\Object_Detection_PyTorch_SSD300_VGG16_Backbone\lib\site-packages\torch\cuda_init_.py", line 186, in _lazy_init check_driver() File "C:\Users\UM6P\anaconda3\envs\Object_Detection_PyTorch_SSD300_VGG16_Backbone\lib\site-packages\torch\cuda_init.py", line 61, in _check_driver raise AssertionError("Torch not compiled with CUDA enabled") AssertionError: Torch not compiled with CUDA enabled

Help me, please !!

ainouch avatar Mar 22 '21 19:03 ainouch

@ainouch have you find the solution for your problem ?

vikas-marwadi avatar Jan 20 '22 08:01 vikas-marwadi