Browse Source
Update readme
Signed-off-by: Jael Gu <mengjia.gu@zilliz.com>
main
1 changed files with
1 additions and
15 deletions
-
README.md
|
@ -19,9 +19,8 @@ The nnfp operator is suitable for audio fingerprinting. |
|
|
|
|
|
|
|
|
Generate embeddings for the audio "test.wav". |
|
|
Generate embeddings for the audio "test.wav". |
|
|
|
|
|
|
|
|
*Write a same pipeline with explicit inputs/outputs name specifications:* |
|
|
|
|
|
|
|
|
*Write a pipeline with explicit inputs/outputs name specifications:* |
|
|
|
|
|
|
|
|
- **option 1 (towhee>=0.9.0):** |
|
|
|
|
|
```python |
|
|
```python |
|
|
from towhee.dc2 import pipe, ops, DataCollection |
|
|
from towhee.dc2 import pipe, ops, DataCollection |
|
|
|
|
|
|
|
@ -36,19 +35,6 @@ DataCollection(p('test.wav')).show() |
|
|
``` |
|
|
``` |
|
|
<img src="./result.png" width="800px"/> |
|
|
<img src="./result.png" width="800px"/> |
|
|
|
|
|
|
|
|
- **option 2:** |
|
|
|
|
|
```python |
|
|
|
|
|
import towhee |
|
|
|
|
|
|
|
|
|
|
|
( |
|
|
|
|
|
towhee.glob['path']('test.wav') |
|
|
|
|
|
.audio_decode.ffmpeg['path', 'frames']() |
|
|
|
|
|
.runas_op['frames', 'frames'](func=lambda x:[y[0] for y in x]) |
|
|
|
|
|
.audio_embedding.nnfp['frames', 'vecs']() |
|
|
|
|
|
.select['path', 'vecs']() |
|
|
|
|
|
.show() |
|
|
|
|
|
) |
|
|
|
|
|
``` |
|
|
|
|
|
<br /> |
|
|
<br /> |
|
|
|
|
|
|
|
|
## Factory Constructor |
|
|
## Factory Constructor |
|
|