plugin does not work with predict command
I've trained a network using the plugin command, and it worked great !
I wanted to test the trained network, with the predict command, but it does not work, and I don't know why:
dnadna predict /home/tau/jcury/DNADNA_project/Experiments/spidna_bact/SPIBact/run_000/SPIBact_run_000_last_epoch_net.pth ~/DATA/BacterialDemoSelection/scenario_00010/*001.npz --plugin local_net.py --debug
an unexpected error occurred: module 'dnadna.nets' has no attribute 'SPIDNA2_fc'; run again with --debug to view the full traceback
an unexpected error occurred: module 'dnadna.nets' has no attribute 'SPIDNA2_fc'; run again with --debug to view the full traceback
Traceback (most recent call last):
File "/home/tau/jcury/miniconda3/envs/dnadna/bin/dnadna", line 33, in <module>
sys.exit(load_entry_point('dnadna', 'console_scripts', 'dnadna')())
File "/home/tau/jcury/DNADNA_project/dnadna/dnadna/utils/cli.py", line 141, in main
raise exc
File "/home/tau/jcury/DNADNA_project/dnadna/dnadna/utils/cli.py", line 133, in main
ret2 = cls.run_subcommand(args)
File "/home/tau/jcury/DNADNA_project/dnadna/dnadna/utils/cli.py", line 102, in run_subcommand
return command_cls.main(command[1:], namespace=args)
File "/home/tau/jcury/DNADNA_project/dnadna/dnadna/utils/cli.py", line 141, in main
raise exc
File "/home/tau/jcury/DNADNA_project/dnadna/dnadna/utils/cli.py", line 125, in main
ret = cls.run(args)
File "/home/tau/jcury/DNADNA_project/dnadna/dnadna/cli/predict.py", line 69, in run
predictor = Predictor.from_net_file(args.model)
File "/home/tau/jcury/DNADNA_project/dnadna/dnadna/prediction.py", line 133, in from_net_file
net_cls = getattr(nets, net_name)
AttributeError: module 'dnadna.nets' has no attribute 'SPIDNA2_fc'
Whereas the command for training was :
dnadna train /home/tau/jcury/DNADNA_project/Experiments/spidna_bact/SPIBact/run_000/SPIBact_000_training_config.yml --plugin local_net.py
I couldn't find why the predict command fails at parsing the plugin file.