|
QDpy
|
Seeded point generators for nearest-centroid archives. More...
Go to the source code of this file.
Namespaces | |
| namespace | qdpy |
Functions | |
| qdpy.containers.centroids.generate_centroids (count, features_domain, *, method="sobol", seed=0, blue_noise_candidates=32) | |
| Generate sites for CVTGrid using unit-cube point sampling. | |
Seeded point generators for nearest-centroid archives.
Definition in file centroids.py.
| qdpy.containers.centroids.generate_centroids | ( | count, | |
| features_domain, | |||
| * | , | ||
| method = "sobol", | |||
| seed = 0, | |||
| blue_noise_candidates = 32 ) |
Generate sites for CVTGrid using unit-cube point sampling.
| count | Number of distinct sites. |
| features_domain | Finite increasing intervals, one per dimension. |
| method | Site generator, "sobol", "halton", "blue-noise", or "uniform". |
| seed | Seed for the private NumPy generator. |
| blue_noise_candidates | Pool size for each best-candidate step. |
Generate sites for ``CVTGrid(centroids=...)`` without changing its default geometry. Scramble Sobol and Halton sequences. Any positive count is supported. For Sobol, retain the prefix of the next power-of-two block. Blue noise starts uniformly and repeatedly selects the best-separated candidate from a fresh uniform pool. Separation is measured in normalized coordinates before applying the requested physical bounds.
Definition at line 34 of file centroids.py.