mirror of
https://github.com/huggingface/candle.git
synced 2025-06-16 10:38:54 +00:00
Expose the weights and biases in transposed convolutions. (#1727)
This commit is contained in:
@ -109,6 +109,14 @@ impl ConvTranspose1d {
|
|||||||
pub fn config(&self) -> &ConvTranspose1dConfig {
|
pub fn config(&self) -> &ConvTranspose1dConfig {
|
||||||
&self.config
|
&self.config
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn weight(&self) -> &Tensor {
|
||||||
|
&self.weight
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn bias(&self) -> Option<&Tensor> {
|
||||||
|
self.bias.as_ref()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl crate::Module for ConvTranspose1d {
|
impl crate::Module for ConvTranspose1d {
|
||||||
@ -258,6 +266,14 @@ impl ConvTranspose2d {
|
|||||||
pub fn config(&self) -> &ConvTranspose2dConfig {
|
pub fn config(&self) -> &ConvTranspose2dConfig {
|
||||||
&self.config
|
&self.config
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn weight(&self) -> &Tensor {
|
||||||
|
&self.weight
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn bias(&self) -> Option<&Tensor> {
|
||||||
|
self.bias.as_ref()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl crate::Module for ConvTranspose2d {
|
impl crate::Module for ConvTranspose2d {
|
||||||
|
Reference in New Issue
Block a user