Skip to main content

Tuner

Struct Tuner 

Source
pub struct Tuner {
    pub manifest: Manifest,
    pub workdir: PathBuf,
    pub store: Store,
    pub backend: Backend,
    /* private fields */
}
Expand description

Aggregated metrics container produced by the tuner.

Fields§

§manifest: Manifest§workdir: PathBuf§store: Store§backend: Backend

Implementations§

Source§

impl Tuner

Source

pub fn new(manifest: Manifest, workdir: impl Into<PathBuf>) -> Tuner

Create a tuner that runs on the local, in-process reference harness.

Source

pub fn with_backend( manifest: Manifest, workdir: impl Into<PathBuf>, backend: Backend, ) -> Tuner

Create a tuner for a specific backend. devbox/cluster delegate trials to the Python worker (which may lift them to real Flyte tasks); local keeps the deterministic offline reference harness.

Source

pub fn load_packs(&mut self) -> Vec<Task>

Load the manifest’s task packs and return the search-split tasks.

Source

pub fn holdout(&self) -> &[Task]

The holdout-split tasks (populated by [load_packs]).

Source

pub fn enumerate_stacks(&self) -> Vec<Stack>

Cartesian product over the manifest’s candidate axes.

Source

pub fn run_trial( &self, stack: &Stack, task: &Task, seed: u64, ws_root: &Path, ) -> TrialResult

Run one trial (copying fixtures, running the harness, grading).

Source

pub fn tune(&mut self) -> Result<Lockfile, Error>

Tune: enumerate, run, aggregate, select, and write harness.lock.

Auto Trait Implementations§

§

impl !RefUnwindSafe for Tuner

§

impl !Send for Tuner

§

impl !Sync for Tuner

§

impl !UnwindSafe for Tuner

§

impl Freeze for Tuner

§

impl Unpin for Tuner

§

impl UnsafeUnpin for Tuner

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.