neighbormodels.interactions.build_model¶
-
build_model(neighbor_data: neighbormodels.neighbors.NeighborData, magnetic_patterns: Dict[str, Union[int, float]], distance_filter: Optional[Dict[str, List[float]]] = None) → pandas.core.frame.DataFrame[source]¶ Builds and returns a data frame describing a pairwise interaction model. The intended use-case for the model is fitting magnetic energies taken from density functional theory calculations and extracting exchange parameters.
Parameters: - neighbor_data –
A named tuple with three field names:
neighbor_count- A pandas
DataFrameof neighbor counts aggregated over site-index pairs and separation distances. sublattice_pairs- A pandas
DataFrameof neighbor distances mapped to unique bin intervals. structure- A copy of the
Structureobject defining the crystal structure.
- magnetic_patterns – A dictionary of magnetic patterns to be mapped onto the crystal structure and used to compute the interaction coefficients of the model.
- distance_filter – A dictionary that defines pair distances to keep in the model. Any pair not found int he dictionary is filtered out. The dictionary keys define named groups of pair distances to keep, which subsequently are used for naming the interaction parameters.
Returns: A pandas
DataFrameof the interaction parameter names and coefficients for the pairwise interaction model.- neighbor_data –