Code Monkey home page Code Monkey logo

Comments (4)

Link-Li avatar Link-Li commented on June 27, 2024

看看是不是dim参数设定错了,看看是不是按我说明输入的

from balanced-dataparallel.

Tonyboy999 avatar Tonyboy999 commented on June 27, 2024

一样的问题,dim用的默认0

from balanced-dataparallel.

zhangyqCS avatar zhangyqCS commented on June 27, 2024

一样的问题,dim用的默认0

请问你解决了吗?我也遇到了同样的问题

from balanced-dataparallel.

zhangyqCS avatar zhangyqCS commented on June 27, 2024

batch_size = 32的时候,报了错,好像跟模型输入有关,没想通哪里错了 model = BalancedDataParallel(8, model, dim=0).cuda()

Traceback (most recent call last): File "train.py", line 580, in main() File "train.py", line 576, in main train(model, logger, device, multi_gpu, pad_idx, train_dataset, validate_dataset, args) File "train.py", line 423, in train pad_idx=pad_idx, args=args) File "train.py", line 290, in train_epoch keyword_ids=keyword_ids) File "/home/workspace/data_parallel.py", line 63, in forward inputs, kwargs = self.scatter(inputs, kwargs, device_ids) File "/home/workspace/data_parallel.py", line 88, in scatter bsz = inputs[0].size(self.dim) IndexError: tuple index out of range

请问你解决了吗?我也遇到了同样的问题

from balanced-dataparallel.

Related Issues (15)

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.