Browse Source
Update
Signed-off-by: Jael Gu <mengjia.gu@zilliz.com>
main
1 changed files with
3 additions and
6 deletions
-
README.md
|
|
@ -16,11 +16,11 @@ The default pretrained model weights are from [The 1st Place Solution of ISC21 ( |
|
|
|
## Code Example |
|
|
|
|
|
|
|
Load an image from path './towhee.jpg' |
|
|
|
and use the pretrained ISC model ('resnet50') to generate an image embedding. |
|
|
|
and use the pretrained ISC model ('resnet50') to generate an image embedding. |
|
|
|
|
|
|
|
*Write a same pipeline with explicit inputs/outputs name specifications:* |
|
|
|
|
|
|
|
- **option 1:** |
|
|
|
- **option 1 (towhee>=0.9.0):** |
|
|
|
|
|
|
|
```python |
|
|
|
from towhee.dc2 import pipe, ops, DataCollection |
|
|
@ -32,7 +32,7 @@ p = ( |
|
|
|
.output('img', 'vec') |
|
|
|
) |
|
|
|
|
|
|
|
DataCollection(p('towhee.jpeg')).show() |
|
|
|
DataCollection(p('towhee.jpg')).show() |
|
|
|
``` |
|
|
|
<img src="./result.png" height="150px"/> |
|
|
|
|
|
|
@ -111,6 +111,3 @@ from towhee import ops |
|
|
|
op = ops.image_embedding.isc().get_op() |
|
|
|
op.save_model('onnx', 'test.onnx') |
|
|
|
``` |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|