Trait candle_lora::Merge

source ·
pub trait Merge {
    // Required methods
    fn get_delta_weight(&self) -> Result<Tensor, MergeErrorOrError>;
    fn merge_weights(&mut self) -> Result<(), MergeErrorOrError>;
    fn unmerge_weights(&mut self) -> Result<(), MergeErrorOrError>;
}

Required Methods§

source

fn get_delta_weight(&self) -> Result<Tensor, MergeErrorOrError>

Get the delta weight of the LoRA layer. This is meant to be an internal method.

source

fn merge_weights(&mut self) -> Result<(), MergeErrorOrError>

Merge the LoRA weights.

source

fn unmerge_weights(&mut self) -> Result<(), MergeErrorOrError>

Unmerge the LoRA weights.

Implementors§