Comments (4)
感谢反馈!您上面提到的“其他任务”是什么任务呢?PaddleHub 文本分类demo中predict.py 用于预测的数据集是 所选数据集的dev部分的前3个数据。
https://github.com/PaddlePaddle/PaddleHub/blob/release/v1.1.0/demo/text-classification/predict.py#L153
from paddlehub.
就是用示例代码做其他数据的文本分类任务,在predict.py的第47行有“dataset = hub.dataset.ChnSentiCorp()”,这个“dataset”在自己的分类数据中是指什么数据呢?还是继续用“dataset = hub.dataset.ChnSentiCorp()”?
from paddlehub.
hub.dataset.ChnSentiCorp() 有三个部分:train,dev,test部分。文本分类demo中 predict.py中预测数据就是 这个数据集的dev部分前三个数据。如果您想替换为自定义数据,可以将自定义数据加载进来,直接用于预测,参考以下写法:
https://github.com/PaddlePaddle/PaddleHub/blob/release/v1.0.0/demo/text-classification/predict.py
如果想利用PaddleHub finetune自定义数据集做文本分类,可以参考
https://github.com/PaddlePaddle/PaddleHub/wiki/PaddleHub%E9%80%82%E9%85%8D%E8%87%AA%E5%AE%9A%E4%B9%89%E6%95%B0%E6%8D%AE%E5%AE%8C%E6%88%90FineTune
from paddlehub.
@Steffy-zxf 好的,谢谢你,我试试自定义的方法。
from paddlehub.
Related Issues (20)
- python 3.9版本和3.8版本安装最新版本paddleHub一直提示包冲突,降级为3.7版本后安装paddlehub==2.1.0和paddle为2.4.2版本又提示另一个包冲突 HOT 3
- bug::AttributeError: module 'paddle' has no attribute 'version' HOT 1
- PaddleHub有效版本 HOT 3
- 多模型串联部署启动后如何调用 HOT 1
- face_landmark_localization 安装报错
- paddlehub调用stable_diffusion生成图片时怎么更改保存的图片名 HOT 2
- paddlehub.module.manager.EnvironmentMismatchError: tsn_kinetics400 cannot be installed because some conditions are not met: HOT 1
- Can't Download HOT 1
- ERROR: Could not build wheels for onnx, which is required to install pyproject.toml-based projects HOT 9
- PaddleHub与PaddlePaddle版本兼容问题 HOT 1
- Enable Private Vulnerability Reporting in GitHub
- 运行代码时报错:生成图片超限,如何解决? HOT 1
- 如何微调? HOT 1
- 请问ernie_skep_sentiment_analysis 有没有文本输入长度限制。
- 在windows图像风格迁移时候最后一步运行style_transfer.py出现报错, UnimplementedError: There are no kernels which are registered in the pad2d operator. [Hint: Expected kernels_iter != all_op_kernels.end(), but received kernels_iter == all_op_kernels.end().] (at ..\paddle\fluid\framework\operator.cc:2273) [operator < pad2d > error] HOT 1
- hub install 命令 或 search 命令 报错 HOT 1
- yolov3_darknet53_pedestrian 每次加载都需要下载很长时间,且推理错误 HOT 4
- 已经停止更新了吗? HOT 4
- DiffSinger 只能使用实例中的那句歌词吗? HOT 1
- 请各位大神帮忙看一下安装报错 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from paddlehub.