Giter Club home page Giter Club logo

Comments (8)

BAAI-OpenPlatform avatar BAAI-OpenPlatform commented on August 28, 2024

你好,有的
可以用superglue的数据集,其中很多都是文本分类任务。这些在FlagAI里是可以自动下载的,数据集介绍见:https://github.com/FlagAI-Open/FlagAI/blob/master/doc_zh/DATASET_EXAMPLE.md

代码参考:https://github.com/FlagAI-Open/FlagAI/blob/master/examples/glm_superglue/train_qqp_pytorch.py,download_path可以改成自己设置的路径

from flagai.

lmolhw5252 avatar lmolhw5252 commented on August 28, 2024

好的谢谢~

from flagai.

lmolhw5252 avatar lmolhw5252 commented on August 28, 2024

另外,在尝试使用roberta_semantic_matching训练时,产生如下问题:

Traceback (most recent call last):
  File "train.py", line 109, in <module>
    main()
  File "train.py", line 101, in main
    trainer.train(model,
  File "/root/anaconda3/envs/py38/lib/python3.8/site-packages/flagai/trainer.py", line 646, in train
    self.evaluate_and_print_results(
  File "/root/anaconda3/envs/py38/lib/python3.8/site-packages/flagai/trainer.py", line 1104, in evaluate_and_print_results
    eval_dict = self.evaluate(forward_step_func=forward_step_func,
  File "/root/anaconda3/envs/py38/lib/python3.8/site-packages/flagai/trainer.py", line 1012, in evaluate
    loss_mask = data_iterator['loss_mask']
KeyError: 'loss_mask'

from flagai.

BAAI-OpenPlatform avatar BAAI-OpenPlatform commented on August 28, 2024

pull最新版本的flagai, 然后在根目录下python setup.py install安装最新版本

from flagai.

lmolhw5252 avatar lmolhw5252 commented on August 28, 2024

已安装版本FlagAI==1.6.1,还是有这个问题

from flagai.

lmolhw5252 avatar lmolhw5252 commented on August 28, 2024

执行example下的glm_superglue的train_large_clue.py文件,同样有这种问题。

from flagai.

BAAI-OpenPlatform avatar BAAI-OpenPlatform commented on August 28, 2024

最新版本的flagai/trainer.py里这一行已经没有了:loss_mask = data_iterator['loss_mask'],所以可能是你没有安装到最新版本,可以先pip uninstall flagai, 然后再安装
或者直接把flagai/trainer.py里这一行去掉再重新安装就行

from flagai.

lmolhw5252 avatar lmolhw5252 commented on August 28, 2024

好的,谢谢~

from flagai.

Related Issues (20)

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.