Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add audio doc #5299

Merged
merged 12 commits into from
Oct 20, 2022
Merged

add audio doc #5299

merged 12 commits into from
Oct 20, 2022

Conversation

SmileGoat
Copy link
Contributor

添加audio对应的api的中文说明

:header: "API 名称", "API 功能"
:widths: 10, 30

" :ref:`LogMelSpectrogram<cn_api_paddle_audio_layers_LogMelSpectrogram>` ", "计算语音特征LogMelSpectrogram"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里的几个超链都失效了哈~
image

.. py:class::paddle.audio.features.LogMelSpectrogram(sr=22050, n_fft=2048, hop_length=512, win_length=None, window='hann', power=2.0, center=True, pad_mode='reflect', n_mels=64, f_min=50.0, f_max=None, htk=False, norm='slaney', ref_value=1.0, amin=1e-10, top_db=None, dtype='float32')

计算给定信号的log-mel谱.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

老师,可以补充一个 “计算公式+公式参数说明: 不? 用户或读不懂怎么计算的。
image

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

建议不要加了,这是信号处理常用特征,直接看源码,比公式更加直接。


LogMelSpectrogram
-------------------------------

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LogMelSpectrogram 有这么多参数,需要写明,以及源代码。
是class类的话,应该参考这么写:
image

总之,需要齐全。

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

部分是没有默认参数的,有默认参数已经添加,源代码链接不知道是什么回事。

-------------------------------

.. py:class::paddle.audio.features.MFCC(sr=22050, n_mfcc=40, n_fft=2048, hop_length=512, win_length=None, window='hann', power=2.0, center=True, pad_mode='reflect', n_mels=64, f_min=50.0, f_max=None, htk=False, norm='slaney', ref_value=1.0, amin=1e-10, top_db=None, dtype='float32')

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

同样的问题,补充:
image

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

有公式,请补充公式。方便用户理解这个方法

-------------------------------

.. py:function::paddle.audio.functional.compute_fbank_matrix(sr, n_fft, n_mels=64, f_min=0.0, f_max=None, htk=False, nrom='slaney', dtype='float32')

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

functional 的写法:参考:

image


.. py:function::paddle.audio.functional.compute_fbank_matrix(sr, n_fft, n_mels=64, f_min=0.0, f_max=None, htk=False, nrom='slaney', dtype='float32')

计算mel变换矩阵.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

补个公式

代码示例
:::::::::

COPY-FROM: paddle.audio.functional.compute_fbank_matrix
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

同样是,示例代码块没找到。
image

Copy link
Collaborator

@momozi1996 momozi1996 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

老师,文档的问题是共性问题,需要在内容上统一修改一下,辛苦了!

文档的格式是没有问题的,目录也对。

Copy link
Collaborator

@momozi1996 momozi1996 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@momozi1996 momozi1996 merged commit 6d16e69 into PaddlePaddle:develop Oct 20, 2022
SmileGoat added a commit to SmileGoat/paddlepaddle_docs that referenced this pull request Feb 8, 2023
* add audio doc

* fix typo

* fix code link && punctuation

* fix typo

* fix features overivew link

* add example

* fix mfcc doc

* add get_window

* update code example

* rm example

* format

* rm code example in cn
dingjiaweiww pushed a commit that referenced this pull request Feb 23, 2023
* add audio doc (#5299)

* add audio doc

* fix typo

* fix code link && punctuation

* fix typo

* fix features overivew link

* add example

* fix mfcc doc

* add get_window

* update code example

* rm example

* format

* rm code example in cn

* update audio datasets && backend (#5363)

* update audio datasets && backend

* add overview

* format

* fix function info

* rm seed in TESS

* rename some api

* fix load

* fix return

* fix codestyle

* [audio] add general_gaussian, rm kaiser in get_window doc (#5378)

* add general_gaussian in get_window doc

* rm kaiser window

* audio backends fix (#5445)

* [audio] fix optional in audio doc (#5609)

---------

Co-authored-by: Ligoml <39876205+Ligoml@users.noreply.github.com>

---------

Co-authored-by: Ligoml <39876205+Ligoml@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants