forked from mindspore-Ecosystem/mindspore
!24271 [assistant][Vol]Enumeration comments supplement
Merge pull request !24271 from QingfengLi/code_docs_vol_enums
This commit is contained in:
commit
45b79cc4ac
|
@ -758,7 +758,7 @@ class Vol(AudioTensorOperation):
|
|||
If gain_type = amplitude, gain stands for nonnegative amplitude ratio.
|
||||
If gain_type = power, gain stands for power.
|
||||
If gain_type = db, gain stands for decibels.
|
||||
gain_type (ScaleType, optional): Type of gain, contains the following three enumeration values
|
||||
gain_type (GainType, optional): Type of gain, contains the following three enumeration values
|
||||
GainType.AMPLITUDE, GainType.POWER and GainType.DB (default=GainType.AMPLITUDE).
|
||||
|
||||
Examples:
|
||||
|
|
|
@ -20,7 +20,18 @@ from enum import Enum
|
|||
|
||||
|
||||
class FadeShape(str, Enum):
|
||||
"""Fade Shape"""
|
||||
"""
|
||||
Fade Shapes.
|
||||
|
||||
Possible enumeration values are: FadeShape.EXPONENTIAL, FadeShape.HALFSINE, FadeShape.LINEAR,
|
||||
FadeShape.LOGARITHMIC, FadeShape.QUARTERSINE.
|
||||
|
||||
- FadeShape.EXPONENTIAL: means the fade shape is exponential mode.
|
||||
- FadeShape.HALFSINE: means the fade shape is half_sine mode.
|
||||
- FadeShape.LINEAR: means the fade shape is linear mode.
|
||||
- FadeShape.LOGARITHMIC: means the fade shape is logarithmic mode.
|
||||
- FadeShape.QUARTERSINE: means the fade shape is quarter_sine mode.
|
||||
"""
|
||||
LINEAR: str = "linear"
|
||||
EXPONENTIAL: str = "exponential"
|
||||
LOGARITHMIC: str = "logarithmic"
|
||||
|
@ -29,13 +40,28 @@ class FadeShape(str, Enum):
|
|||
|
||||
|
||||
class GainType(str, Enum):
|
||||
"""Gain Type"""
|
||||
""""
|
||||
Gain Types.
|
||||
|
||||
Possible enumeration values are: GainType.AMPLITUDE, GainType.DB, GainType.POWER.
|
||||
|
||||
- GainType.AMPLITUDE: means input gain type is amplitude.
|
||||
- GainType.DB: means input gain type is decibel.
|
||||
- GainType.POWER: means input gain type is power.
|
||||
"""
|
||||
POWER: str = "power"
|
||||
AMPLITUDE: str = "amplitude"
|
||||
DB: str = "db"
|
||||
|
||||
|
||||
class ScaleType(str, Enum):
|
||||
"""Scale Type"""
|
||||
"""
|
||||
Scale Types.
|
||||
|
||||
Possible enumeration values are: ScaleType.MAGNITUDE, ScaleType.POWER.
|
||||
|
||||
- ScaleType.MAGNITUDE: means the scale of input audio is magnitude.
|
||||
- ScaleType.POWER: means the scale of input audio is power.
|
||||
"""
|
||||
POWER: str = "power"
|
||||
MAGNITUDE: str = "magnitude"
|
||||
|
|
Loading…
Reference in New Issue