apollon.som.datasets module¶
apollon/som/datasets.py
Licensed under the terms of the BSD-3-Clause license. Copyright (C) 2019 Michael Blaß mblass@posteo.net
Function for generating test and illustration data sets.
-
apollon.som.datasets.
norm_circle
(n_classes: int, n_per_class: int, class_std: int, center: Tuple[int, int] = (0, 0), radius: int = 5, seed: Optional[int] = None)¶ Generate
n_per_class
samples fromn_classes
bivariate normal distributions, each with standard deviationclass_std
. The means are equidistantly placed on a circle with radiusradius
.- Parameters
n_classes – Number of classes.
n_per_class – Number of samples in each class.
class_std – Standard deviation for every class.
center – Center of ther circle.
radius – Radius of the circle on which the means are placed.
seed – Set the random seed.
- Returns
Data set and target vector.