Struct candle_lora::LoraConv2d
source · pub struct LoraConv2d { /* private fields */ }
Implementations§
source§impl LoraConv2d
impl LoraConv2d
pub fn new( old: &dyn Conv2dLayerLike, conv_config: &LoraConv2dConfig, config: &LoraConfig, vb: &VarBuilder<'_>, id: usize, ) -> Result<Self>
Trait Implementations§
source§impl Clone for LoraConv2d
impl Clone for LoraConv2d
source§fn clone(&self) -> LoraConv2d
fn clone(&self) -> LoraConv2d
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Conv2dLayerLike for LoraConv2d
impl Conv2dLayerLike for LoraConv2d
source§impl Debug for LoraConv2d
impl Debug for LoraConv2d
source§impl Merge for LoraConv2d
impl Merge for LoraConv2d
source§fn get_delta_weight(&self) -> Result<Tensor, MergeErrorOrError>
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>
fn merge_weights(&mut self) -> Result<(), MergeErrorOrError>
Merge the LoRA weights.
source§fn unmerge_weights(&mut self) -> Result<(), MergeErrorOrError>
fn unmerge_weights(&mut self) -> Result<(), MergeErrorOrError>
Unmerge the LoRA weights.
source§impl Saveable for LoraConv2d
impl Saveable for LoraConv2d
fn get_tensors(&self, accum: &mut HashMap<String, Tensor>)
Auto Trait Implementations§
impl Freeze for LoraConv2d
impl !RefUnwindSafe for LoraConv2d
impl Send for LoraConv2d
impl Sync for LoraConv2d
impl Unpin for LoraConv2d
impl !UnwindSafe for LoraConv2d
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more