A sampler which returns the nearest values between the input samples and the allowed values, without replacement.
Project description
AutoRA Nearest Value Sampler
A sampler which returns the nearest values between the input samples and the allowed values, without replacement.
Example Code
from autora.experimentalist.sampler.nearest_value import nearest_values_sampler
import numpy as np
#Meta-Setup
X_allowed = np.linspace(-3, 6, 10)
X = np.random.choice(X_allowed,10)
n = 5
#Sampler
X_new = nearest_values_sampler(X, X_allowed, n)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for autora-experimentalist-sampler-nearest-value-1.0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | e173a58c94b603b845090e4e9a3e4a78eb3b97c4fdc4897824ef96de797548a2 |
|
MD5 | a28439165d7d2eab5db4708c246e422a |
|
BLAKE2b-256 | 4d88a4ed448660b2c6e53c99eff4542ee9cc75bc3cd4746661e6b9d7b462c413 |
Close
Hashes for autora_experimentalist_sampler_nearest_value-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 69821e675355cadd4a9daf5954d9c4c7180b944967d3acaec21eec62746df462 |
|
MD5 | 037e2e9ac696481533c5decb659d3c1b |
|
BLAKE2b-256 | 018e702892586afdf48bdf1273ac18fc5fcdd8e8dbdc4d00678aa8192b5d02f8 |