Compares weaknesses in multiple models
Project description
AutoRA Model Disagreement Sampler
The model disagreement sampler identifies experimental conditions $\vec{x}' \in X'$ with respect to a pairwise distance metric between theorist models, $P_{M_{i}}(\hat{y}, \vec{x}')$:
$$ \underset{\vec{x}'}{\arg\max}~(P_{M_{1}}(\hat{y}, \vec{x}') - P_{M_{2}}(\hat{y}, \vec{x}'))^2 $$
Example Code
from autora.experimentalist.sampler.model_disagreement import model_disagreement_sampler
from autora.theorist.bms import BMSRegressor; BMSRegressor()
from autora.theorist.darts import DARTSRegressor; DARTSRegressor()
import numpy as np
#Meta-Setup
X = np.linspace(start=-3, stop=6, num=10).reshape(-1, 1)
y = (X**2).reshape(-1, 1)
n = 5
#Theorists
bms_theorist = BMSRegressor()
darts_theorist = DARTSRegressor()
bms_theorist.fit(X,y)
darts_theorist.fit(X,y)
#Sampler
X_new = model_disagreement_sampler(X, [bms_theorist, darts_theorist], n)
Project details
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-model-disagreement-1.0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | afcb1d37ebf7fe25cfe3f008e8381325ff70b3931be9432d6ce0d75f7e19766c |
|
MD5 | e267023aca9ba43e86a145c6be25d2a4 |
|
BLAKE2b-256 | d17365883a7e23c361651fa6d6a99562ff83bf5641fbd87187345a60a2e48cb5 |
Close
Hashes for autora_experimentalist_sampler_model_disagreement-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4c48e6333ef359db0c4c61263f7fa699215b69e728e141d8482b96d520c17c4f |
|
MD5 | 2ef1bda1b1c1e9d1919150ae36a859de |
|
BLAKE2b-256 | f3ee2922b12ba766c2f0b640141ed266292bb1fd9ec8b52c0e1fd3d08edba491 |