-
-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
added household chemicals #340
base: development
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few things about your code:
- Class names should always be pascal case (eg CorrectClassName)
- Node names should be snake case (eg correct_node_name)
- Dictionaries should have correct indentation and formatting. See other dictionaries in global-chem for examples.
- Some SMILES in your code are invalid. Please use rdkit to double check all SMILES are valid before creating pull request. You can use
Chem.MolFromSmiles(smiles)
to see if there is an error.
Other Changes:
- Change
README.md
to add your node to the list and any references you used - In
global_chem/global_chem/global_chem.py
you need to import your nodes at the top (egfrom global_chem.environment.chemicals_from_biomass import ChemicalsFromBioMass
)
from global_chem.household_chemicals.organophosphate_flame_retardants import Organophosphate_flame_retardants | ||
from global_chem.household_chemicals.Surface_cleaners import Surface_cleaners |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Class names should be all capitalized to match coding style.
from global_chem.household_chemicals.organophosphate_flame_retardants import Organophosphate_flame_retardants | |
from global_chem.household_chemicals.Surface_cleaners import Surface_cleaners | |
from global_chem.household_chemicals.organophosphate_flame_retardants import OrganophosphateFlameRetardants | |
from global_chem.household_chemicals.surface_cleaners import SurfaceCleaners |
@@ -492,6 +492,7 @@ class GlobalChem(object): | |||
'mango_vitamins': MangoVitamins, # Damilola Bodun & Sevien Schulhofff | |||
'mango_flavonoids': MangoFlavonoids, # Damilola Bodun & Sevien Schulhofff | |||
'insect_sex_pheromones': InsectSexPheromones, # Yuqing Liu & Suliman Sharif | |||
'household_chemicals' : household_chemicals, # Kalana Kotawalagedara & Anuththara Gamage |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should add an entry to this list for every node, not just the folder household chemicals.
'household_chemicals' : household_chemicals, # Kalana Kotawalagedara & Anuththara Gamage | |
'bleach' : Bleach, # Kalana Kotawalagedara & Anuththara Gamage | |
’cosmetics’: Cosmetics, # Kalana Kotawalagedara & Anuththara Gamage | |
# …etc |
smarts = { | ||
|
||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indent to match coding style.
smarts = { | |
} | |
smarts = { | |
} |
smiles = { | ||
'oxybenzone' : 'COC1=CC(=C(C=C1)C(=O)C2=CC=CC=C2)O', | ||
'hydroquinone' : 'C1=CC(=CC=C1O)O', | ||
'diethyl phthalate' : 'CCOC(=O)C1=CC=CC=C1C(=O)OCC', | ||
|
||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indent to match coding style.
smiles = { | |
'oxybenzone' : 'COC1=CC(=C(C=C1)C(=O)C2=CC=CC=C2)O', | |
'hydroquinone' : 'C1=CC(=CC=C1O)O', | |
'diethyl phthalate' : 'CCOC(=O)C1=CC=CC=C1C(=O)OCC', | |
} | |
smiles = { | |
'oxybenzone' : 'COC1=CC(=C(C=C1)C(=O)C2=CC=CC=C2)O', | |
'hydroquinone' : 'C1=CC(=CC=C1O)O', | |
'diethyl phthalate' : 'CCOC(=O)C1=CC=CC=C1C(=O)OCC', | |
} |
'hydrochloric acid' : 'Cl', | ||
'brass' : ' [Cu].[Zn].[Pb]', | ||
'chloroxylenol' : 'CC1=CC(=CC(=C1Cl)C)O', | ||
'1,4- dioxane' : 'C1COCCO1', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No space after dash in IUPAC
'1,4- dioxane' : 'C1COCCO1', | |
'1,4-dioxane' : 'C1COCCO1', |
'triclosan' : 'C1=CC(=C(C=C1Cl)O)OC2=C(C=C(C=C2)Cl)Cl', | ||
'benzalkonium chloride' : '[Cl-].CCCCCCCCCCCCN+(C)CC1=CC=CC=C1', | ||
'isopropyl alcohol' : 'CC(C)O', | ||
'chlorohexidine' : r 'C1=CC(=CC=C1N/C(=N/C(=NCCCCCCN=C(/N=C(/NC2=CC=C(C=C2)Cl)\N)N)N)/N)Cl', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Incorrect name
'chlorohexidine' : r 'C1=CC(=CC=C1N/C(=N/C(=NCCCCCCN=C(/N=C(/NC2=CC=C(C=C2)Cl)\N)N)N)/N)Cl', | |
'chlorhexidine' : r 'C1=CC(=CC=C1N/C(=N/C(=NCCCCCCN=C(/N=C(/NC2=CC=C(C=C2)Cl)\N)N)N)/N)Cl', |
'phenol' : 'C1=CC=C(C=C1)O', | ||
'formaldehyde' : 'C=O', | ||
'boric acid' : 'B(O)(O)O', | ||
'triclosan' : 'C1=CC(=C(C=C1Cl)O)OC2=C(C=C(C=C2)Cl)Cl', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Duplicate
'triclosan' : 'C1=CC(=C(C=C1Cl)O)OC2=C(C=C(C=C2)Cl)Cl', |
'boric acid' : 'B(O)(O)O', | ||
'triclosan' : 'C1=CC(=C(C=C1Cl)O)OC2=C(C=C(C=C2)Cl)Cl', | ||
'oligo(2-(2-ethoxy)-ethoxyethyl)guanidinium chloride' : 'Cl.NC(N)=N.NCCOCCOCCN', | ||
'polyhexamethylene guanidine' : 'Cl.NC(N)=N.NCCCCCCN', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
def get_smiles(): | ||
|
||
smiles = { | ||
'tris(1,3-dichloro-2-propyl)phosphate' : 'C(C(CCl)OP(=O)(OC(CCl)CCl)OC(CCl)CCl)Cl', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing a space.
'tris(1,3-dichloro-2-propyl)phosphate' : 'C(C(CCl)OP(=O)(OC(CCl)CCl)OC(CCl)CCl)Cl', | |
'tris(1,3-dichloro-2-propyl) phosphate' : 'C(C(CCl)OP(=O)(OC(CCl)CCl)OC(CCl)CCl)Cl', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @Lyq322.
@kalanakotawalagedara go through above mistakes, discuss with yuquing about them correct all of them.
added bleach, detergents,disinfectants,cosmetics, surface cleaners and flame retardants SMILES