Skip to content

Problem in Loss Func. Use ICDAR2015 to train to model, but this problem emerged. #9

@leonrenlang

Description

@leonrenlang

File "/workspace/PixelLink-with-pytorch/main.py", line 144, in
main()
File "/workspace/PixelLink-with-pytorch/main.py", line 133, in main
train(config.epoch, iteration, dataloader, my_net, optimizer, optimizer2, device)
File "/workspace/PixelLink-with-pytorch/main.py", line 73, in train
pixel_pos_weights)
File "/workspace/PixelLink-with-pytorch/criterion.py", line 46, in pixel_loss
self.neg_pixel_weight[i] = self.neg_pixel_weight[i] & (neg_pixel_masks[i]==1)
RuntimeError: Expected object of scalar type Byte but got scalar type Bool for argument #2 'other' in call to _th_and

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions