Giter Club home page Giter Club logo

pcb's People

Contributors

yypurpose avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

pcb's Issues

run on single GPU

Hello, thank you very much for your work. When I reproduce your code, I find that the code cannot run on a single GPU, and the following error occurs. I would like to ask how to run code on a single GPU.

RuntimeError: MaskRCNN: IterativeRoIHead: Shared2FCBBoxHead: CrossEntropyPCBLoss: Default process group has not been initialized, please make sure to call init_process_group.

A potential bug in gathering data from multiple processes

Hi, I encountered a stuck issue when training in DDP, and here is the reason I figured out:

pos_inds = label < self.num_classes
neg_inds = label == self.num_classes
if pos_inds.sum() > 0:
pred_fg_distri = F.softmax(cls_score[pos_inds, :self.num_classes], dim=1)
fg_confusion_matrix_tmp = torch.zeros_like(self.fg_confusion_matrix).scatter_add_(0, label[pos_inds].view(-1,1).repeat(1,self.num_classes), pred_fg_distri)
fg_confusion_matrix_tmp_pool = [torch.zeros_like(fg_confusion_matrix_tmp) for i in range(torch.distributed.get_world_size())]
torch.distributed.all_gather(fg_confusion_matrix_tmp_pool, fg_confusion_matrix_tmp)
fg_confusion_matrix_tmp = sum(fg_confusion_matrix_tmp_pool)

the if branch starting from line 284 may be entered for some processes, and may not for others (e.g. some training images contain no labelled instance), so the gather function in line 289 will permanently wait for those processes that never execute line 284~288.

One possible solution is to check if all processes satisfy pos_inds.sum() > 0. If not, do not update the confusion matrix.

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.