#[non_exhaustive]pub struct StftOptions {
pub hop_length: Option<usize>,
pub win_length: Option<usize>,
pub center: bool,
pub pad_mode: StftPadMode,
pub normalized: bool,
pub onesided: bool,
}Expand description
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.hop_length: Option<usize>フレーム間隔。None は n_fft/4(0 になる n_fft < 4 では拒否)。
win_length: Option<usize>窓長。None は n_fft。window の長さと一致する必要がある。
center: booltrue なら両端を n_fft/2 拡張してからフレーム化する。
pad_mode: StftPadModecenter = true 時の端パディング種別。
normalized: booltrue なら 1/√n_fft で正規化する(false はスケールなし)。
onesided: booltrue なら片側スペクトル(n_fft/2+1 bin)、false なら全 bin。
Implementations§
Source§impl StftOptions
impl StftOptions
Sourcepub fn with_hop_length(self, hop_length: usize) -> StftOptions
pub fn with_hop_length(self, hop_length: usize) -> StftOptions
フレーム間隔を設定する。
Sourcepub fn with_win_length(self, win_length: usize) -> StftOptions
pub fn with_win_length(self, win_length: usize) -> StftOptions
窓長を設定する。
Sourcepub fn with_center(self, center: bool) -> StftOptions
pub fn with_center(self, center: bool) -> StftOptions
両端パディングの有無を設定する。
Sourcepub fn with_pad_mode(self, pad_mode: StftPadMode) -> StftOptions
pub fn with_pad_mode(self, pad_mode: StftPadMode) -> StftOptions
端パディング種別を設定する。
Sourcepub fn with_normalized(self, normalized: bool) -> StftOptions
pub fn with_normalized(self, normalized: bool) -> StftOptions
正規化の有無を設定する。
Sourcepub fn with_onesided(self, onesided: bool) -> StftOptions
pub fn with_onesided(self, onesided: bool) -> StftOptions
片側スペクトルか否かを設定する。
Trait Implementations§
Source§impl Clone for StftOptions
impl Clone for StftOptions
Source§fn clone(&self) -> StftOptions
fn clone(&self) -> StftOptions
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for StftOptions
Source§impl Debug for StftOptions
impl Debug for StftOptions
Source§impl Default for StftOptions
impl Default for StftOptions
Source§fn default() -> StftOptions
fn default() -> StftOptions
Returns the “default value” for a type. Read more
impl Eq for StftOptions
Source§impl PartialEq for StftOptions
impl PartialEq for StftOptions
impl StructuralPartialEq for StftOptions
Auto Trait Implementations§
impl Freeze for StftOptions
impl RefUnwindSafe for StftOptions
impl Send for StftOptions
impl Sync for StftOptions
impl Unpin for StftOptions
impl UnsafeUnpin for StftOptions
impl UnwindSafe for StftOptions
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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