GithubHelp home page GithubHelp logo

求解答 about news-text-classification HOT 2 OPEN

hchhtc123 avatar hchhtc123 commented on August 30, 2024
求解答

from news-text-classification.

Comments (2)

liuxiaobei6667 avatar liuxiaobei6667 commented on August 30, 2024

ValueError Traceback(最近一次调用最后一次) /tmp/ipykernel_203/1672709690.py in 4 5 ----> 6 train_ds, dev_ds = load_dataset(splits=["train", "dev"])

/tmp/ipykernel_203/1062691189.py in load_dataset(name, data_files, splits, lazy, **kwargs) 45 reader_instance = reader_cls(lazy=lazy, name=name, **kwargs) 46 ---> 47 datasets = reader_instance. read_datasets(data_files=data_files,splits=splits) 48 返回数据集

/opt/conda/envs/python35-paddle120-env/lib/python3.7/site-packages/paddlenlp/datasets/dataset.py in read_datasets(self, splits, data_files) 526 而不是 os.path.exists(lock_file) : 527 time.sleep(1) --> 528 datasets.append(self.read(filename=filename, split=split)) 529 530 if data_files:

/opt/conda/envs/python35-paddle120-env/lib/python3.7/site-packages/paddlenlp/datasets/dataset.py in read(self, filename, split) 633 raise ValueError( 634 "没有实例被读取给定的文件路径 {}." --> 635 "路径是否正确?".format(filename)) 636 637 # 我们需要检查示例是否包含标签列并确认其名称。

ValueError:没有从给定的文件路径 dev.csv 读取实例。路径是否正确?

改了部分代码。把训练集和验证集换成了自己得数据
image

from news-text-classification.

hchhtc123 avatar hchhtc123 commented on August 30, 2024

换成自己数据集的话,你可以检查下数据集的位置是否正确(若不确定相对路径可以使用绝对路径试试)。
若数据集位置没有问题的话,可能检查下数据的存储是否为两列且每列是否是以\t分隔。

from news-text-classification.

Related Issues (1)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.