API reference for lipids submodule#

Module for the lipid topology json files.

This module contains functions for parsing the json files.

buildh.lipids.check_topology(universe, lipid_top)#

Check if the topology lipid_top is coherent with the structure in universe.

This function check first the lipid residue name then the atoms in the topology. This function return false if there is one missing in the structure. Print also an error message.

Parameters
  • universe (MDAnalysis universe instance) –

  • lipid_top (dictionary) – lipid topology for hydrogen.

Returns

whether the structure and the topology match

Return type

Boolean

buildh.lipids.read_lipids_topH(filenames)#

Generate a list of lipid hydrogen topologies.

This function read a list of json files containing the topology of a united-atom lipid for reconstructing the missing hydrogens.

The list topologies is stored as dictionary were the key is “ForceField_lipidname” (e.g Berger_POPC, CHARMM_DMPC). If there is multiple lipid residue name in the key ‘resname’ of the json, it will create one dictionary for one element of this key.

Parameters

filenames (list of str) – List of json files containing topologies.

Returns

the lipid topologies.

Return type

dictionary of dictionary

Raises

ValueError – When a file doesn’t have a correct format.