SiteStatsFingerprint
- class emmet.core.featurization.featurizers.SiteStatsFingerprint(site_featurizer=<factory>, stats=<factory>)
Bases:
FeaturizerComputes statistics of properties across all sites in a structure.
Adapted and simplified significantly from matminer.featurizers.structure.sites.
- Args:
- site_featurizerFeaturizer
Featurization to use on each site of a structure.
- statslist of str
Should be a list of statistics in FeatureStats
- Parameters:
site_featurizer (Featurizer)
stats (list[str])
- static get_stat(op, vals)
Compute statistics of a 1-D array.
- Return type:
float- Parameters:
op (str | FeatureStats)
vals (list[float])
- Args:
- opstr or FeatureStats
A statistic name to compute
- valslist[float]
An ordered list of floats
- Returns:
float, the statistic
- featurize(s)
Main featurizer function, which has to be implemented in any derived featurizer subclass.
- Return type:
list[float] |list[list[float]]- Parameters:
s (Structure)
- Args:
x: input data to featurize (type depends on featurizer).
- Returns:
(list) one or more features.
- property feature_labels: list[str]
Generate feature labels.
- Returns:
list of str, the labels of the features