Skip to content

feat: cardiolipins are now named according to the common convention - #514

Merged
comcon1 merged 1 commit into
NMRLipids:mainfrom
comcon1:fix-CL-oprenamer
Jun 27, 2026
Merged

feat: cardiolipins are now named according to the common convention#514
comcon1 merged 1 commit into
NMRLipids:mainfrom
comcon1:fix-CL-oprenamer

Conversation

@comcon1

@comcon1 comcon1 commented Jun 27, 2026

Copy link
Copy Markdown
Member

This code

#!/usr/bin/env python3
from fairmd.lipids.core import initialize_databank
from fairmd.lipids import api
from fairmd.lipids.auxiliary import opconvertor
import pprint
ss = initialize_databank()
s = ss.loc(827)
opd = api.get_OP(s)
n = opconvertor.build_nice_OPdict(opd["TMCL"], s.lipids["TMCL"])
pprint.pprint(n)

Gives now this renaming:

{'glycerol backbone 1': [{'C': 'g1',
                          'H': '1',
                          'OP': -0.0448744,
                          'STD': 0.0357943},
                         {'C': 'g1', 'H': '2', 'OP': -0.1751, 'STD': 0.0320824},
                         {'C': 'g2',
                          'H': '1',
                          'OP': -0.181452,
                          'STD': 0.0295574},
                         {'C': 'g3',
                          'H': '1',
                          'OP': -0.243936,
                          'STD': 0.0252524},
                         {'C': 'g3',
                          'H': '2',
                          'OP': -0.214915,
                          'STD': 0.0308774}],
 'glycerol backbone 2': [{'C': 'g1',
                          'H': '1',
                          'OP': -0.174946,
                          'STD': 0.0300904},
                         {'C': 'g1',
                          'H': '2',
                          'OP': -0.0451302,
                          'STD': 0.0313436},
                         {'C': 'g2',
                          'H': '1',
                          'OP': -0.181545,
                          'STD': 0.0319113},
                         {'C': 'g3',
                          'H': '1',
                          'OP': -0.211739,
                          'STD': 0.0341871},
                         {'C': 'g3',
                          'H': '2',
                          'OP': -0.245898,
                          'STD': 0.0216968}],
 'headgroup': [{'C': "g1'", 'H': '1', 'OP': 0.0600742, 'STD': 0.0243621},
               {'C': "g1'", 'H': '2', 'OP': 0.0971831, 'STD': 0.0232866},
               {'C': "g2'", 'H': '1', 'OP': 0.0991765, 'STD': 0.0231395},
               {'C': "g3'", 'H': '1', 'OP': 0.0417517, 'STD': 0.0234833},
               {'C': "g3'", 'H': '2', 'OP': 0.115969, 'STD': 0.0249795}],
 'sn-1 1': [{'C': '2', 'H': '1', 'OP': -0.237052, 'STD': 0.019649},
            {'C': '2', 'H': '2', 'OP': -0.208036, 'STD': 0.0239502},
            {'C': '3', 'H': '1', 'OP': -0.175971, 'STD': 0.0147601},
            {'C': '3', 'H': '2', 'OP': -0.167442, 'STD': 0.0159514},
            {'C': '4', 'H': '1', 'OP': -0.199878, 'STD': 0.013414},
// ...
            {'C': '13', 'H': '1', 'OP': -0.0928769, 'STD': 0.0067256},
            {'C': '13', 'H': '2', 'OP': -0.0919833, 'STD': 0.00688426},
            {'C': '14', 'H': '1', 'OP': -0.0326735, 'STD': 0.00385615},
            {'C': '14', 'H': '2', 'OP': -0.0323991, 'STD': 0.0037793},
            {'C': '14', 'H': '3', 'OP': -0.0326691, 'STD': 0.00367202}],
 'sn-1 2': [{'C': '2', 'H': '1', 'OP': -0.242656, 'STD': 0.0169693},
            {'C': '2', 'H': '2', 'OP': -0.211591, 'STD': 0.0182651},
            {'C': '3', 'H': '1', 'OP': -0.179941, 'STD': 0.0139942},
            {'C': '3', 'H': '2', 'OP': -0.170615, 'STD': 0.0127402},
            {'C': '4', 'H': '1', 'OP': -0.203546, 'STD': 0.0119704},
            {'C': '4', 'H': '2', 'OP': -0.202832, 'STD': 0.011782},
            {'C': '5', 'H': '1', 'OP': -0.200352, 'STD': 0.0121586},
      // ...
            {'C': '14', 'H': '1', 'OP': -0.0328502, 'STD': 0.00375039},
            {'C': '14', 'H': '2', 'OP': -0.0336922, 'STD': 0.00383654},
            {'C': '14', 'H': '3', 'OP': -0.0325867, 'STD': 0.00485332}],
 'sn-2 1': [{'C': '2', 'H': '1', 'OP': -0.0806543, 'STD': 0.0225526},
            {'C': '2', 'H': '2', 'OP': -0.117309, 'STD': 0.0189882},
            {'C': '3', 'H': '1', 'OP': -0.203257, 'STD': 0.0143669},
            {'C': '3', 'H': '2', 'OP': -0.206751, 'STD': 0.0143241},
            {'C': '4', 'H': '1', 'OP': -0.210911, 'STD': 0.0136645},
            {'C': '4', 'H': '2', 'OP': -0.21331, 'STD': 0.0138081},
            {'C': '5', 'H': '1', 'OP': -0.221195, 'STD': 0.0140054},
            {'C': '5', 'H': '2', 'OP': -0.219976, 'STD': 0.0145714},
            {'C': '6', 'H': '1', 'OP': -0.213504, 'STD': 0.0149589},
   // ...
            {'C': '13', 'H': '2', 'OP': -0.10862, 'STD': 0.00935321},
            {'C': '14', 'H': '1', 'OP': -0.0275731, 'STD': 0.00399158},
            {'C': '14', 'H': '2', 'OP': -0.02711, 'STD': 0.00377359},
            {'C': '14', 'H': '3', 'OP': -0.0274805, 'STD': 0.00348814}],
 'sn-2 2': [{'C': '2', 'H': '1', 'OP': -0.0840992, 'STD': 0.0245398},
            {'C': '2', 'H': '2', 'OP': -0.11595, 'STD': 0.0198196},
            {'C': '3', 'H': '1', 'OP': -0.205055, 'STD': 0.015776},
            {'C': '3', 'H': '2', 'OP': -0.207858, 'STD': 0.0149858},
   // ...
            {'C': '13', 'H': '1', 'OP': -0.109674, 'STD': 0.00979831},
            {'C': '13', 'H': '2', 'OP': -0.109823, 'STD': 0.00939368},
            {'C': '14', 'H': '1', 'OP': -0.0273625, 'STD': 0.00397343},
            {'C': '14', 'H': '2', 'OP': -0.0281593, 'STD': 0.00394679},
            {'C': '14', 'H': '3', 'OP': -0.0274527, 'STD': 0.00454932}]}


📚 Documentation preview 📚: https://databank--514.org.readthedocs.build/

@comcon1
comcon1 requested a review from mdondrup June 27, 2026 07:07

@mdondrup mdondrup left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great. I ran it through the UI updater, nothing unexpected, and all the new names accounted for. We need to manually start the UI update github action after this is merged into main.

@comcon1
comcon1 merged commit 62b18e6 into NMRLipids:main Jun 27, 2026
8 of 10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants