#Description of model is at the paper, "Predicting Potentially Hazardous Chemical Reactions Using Explainable Neural Network"
#REQUIREMENTS python : 3.7 rdkit : 2019.03.4 torch : 1.2.0 sklearn : 0.23.2
#GUIDE FOR USE
- Reaction data is from USPTO data and reaxys data
- Cleaned data is located at ./data/toxin/ and ./data/explosive/
- Reaction data which converted into fingerprints are located at ./data/fp/toxin/[nameoftoxin]/ and ./data/fp/explosive/[nameofexplosive]/
- Or you can use ./data/fp/convert_to_fingerprint.py to convert reaction data into fingerprint data
- You can train the prediction model using ./train.py
- You can test and check result of the prediction using ./test.py
#convert_to_fingerprint.py
- The location of positive and negative data, and output directory should be set
- Radius us the maximum size of fingerprint substructure from center atom, and frequent regulate is minimum frequency that required for substructure to be included in library
- Output is test, validation, training data with reactions, library describes substructures to fingerprints, test, validation, training data which converted into fingerprints
#train.py
- The location of library, training data, validation data and output directory should be set
- radius and frequent regulate should be same with fingerpritn converting option
- maxlen is maximum number of molecules in reaction, and decay is option used to change gradient descent optimization
- Output is trained path as .pth file
#test.py
- The location of library, test data, trained path(.pth file) and output directory should be set
- Other options should be same with option used to train model
- Ouput is final test accuracy of model for positive and negative test set
#predict.py
- The location of library, test reactions, trained path and output directory should be set
- Other options should be same with option used to train model
- Ouput is predictions