Trait openml::Task [−][src]
pub trait Task { fn id(&self) -> &str; fn name(&self) -> &str; fn run_static<X, Y, F, M>(&self, flow: F) -> M
where
F: Fn(&mut Iterator<Item = (&X, &Y)>, &mut Iterator<Item = &X>) -> Box<Iterator<Item = Y>>,
X: DeserializeOwned,
Y: DeserializeOwned,
M: MeasureAccumulator<Y>; fn run<X, Y, F, M>(&self, flow: F) -> M
where
F: Fn(&mut Iterator<Item = (&[X], &Y)>, &mut Iterator<Item = &[X]>) -> Box<Iterator<Item = Y>>,
X: DeserializeOwned,
Y: DeserializeOwned,
M: MeasureAccumulator<Y>; }
Required Methods
fn id(&self) -> &str
get task ID
fn name(&self) -> &str
get task name
fn run_static<X, Y, F, M>(&self, flow: F) -> M where
F: Fn(&mut Iterator<Item = (&X, &Y)>, &mut Iterator<Item = &X>) -> Box<Iterator<Item = Y>>,
X: DeserializeOwned,
Y: DeserializeOwned,
M: MeasureAccumulator<Y>,
F: Fn(&mut Iterator<Item = (&X, &Y)>, &mut Iterator<Item = &X>) -> Box<Iterator<Item = Y>>,
X: DeserializeOwned,
Y: DeserializeOwned,
M: MeasureAccumulator<Y>,
run task, specifying the type of an entire feature column in X
. This allows to run
machine learning models that take features of different types, or named features in form
of structs.
fn run<X, Y, F, M>(&self, flow: F) -> M where
F: Fn(&mut Iterator<Item = (&[X], &Y)>, &mut Iterator<Item = &[X]>) -> Box<Iterator<Item = Y>>,
X: DeserializeOwned,
Y: DeserializeOwned,
M: MeasureAccumulator<Y>,
F: Fn(&mut Iterator<Item = (&[X], &Y)>, &mut Iterator<Item = &[X]>) -> Box<Iterator<Item = Y>>,
X: DeserializeOwned,
Y: DeserializeOwned,
M: MeasureAccumulator<Y>,
run task, specifying the feature type in X
. This allows to run machine learning models
that expect every feature to have the same type.