[−][src]Struct sticker::LayerEmbeddings
Embeddings for annotation layers.
This data structure bundles embedding matrices for the input annotation layers: tokens and part-of-speech.
Methods
impl LayerEmbeddings
[src]
pub fn new(
token_embeddings: Embeddings,
tag_embeddings: Option<Embeddings>
) -> Self
[src]
token_embeddings: Embeddings,
tag_embeddings: Option<Embeddings>
) -> Self
Construct LayerEmbeddings
from the given embeddings.
pub fn tag_embeddings(&self) -> Option<&Embeddings>
[src]
Get the tag embedding matrix.
pub fn token_embeddings(&self) -> &Embeddings
[src]
Get the token embedding matrix.
Auto Trait Implementations
impl Sync for LayerEmbeddings
impl Send for LayerEmbeddings
impl Unpin for LayerEmbeddings
impl RefUnwindSafe for LayerEmbeddings
impl UnwindSafe for LayerEmbeddings
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,