Skip to content

Commit

Permalink
lipidmaps: foreign IDs in resource class
Browse files Browse the repository at this point in the history
  • Loading branch information
deeenes committed Nov 20, 2024
1 parent 2020785 commit dc262d3
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions omnipath_metabo/schema/_structure.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,11 +194,14 @@ def __iter__(self):

yield {
'structure':(met['id'], smiles, met['name']['INCHI']),
'properties':(met['annot'].get('EXACT_MASS', None),
None,
None,
'properties':(met['annot'].get('EXACT_MASS', None),
None,
None,
met['name'].get('FORMULA', None)),
'identifiers':(met['PUBCHEM_CID'], met['CHEBI_ID'])
'identifiers': [
(met.get(k[0], {}).get(k[1], None), k[1])
for k in self.id_fields
]
}

class Ramp(ResourceBase):
Expand Down

0 comments on commit dc262d3

Please sign in to comment.