Skip to content

TypeError: __init__() got an unexpected keyword argument 'num_points' #24

Closed
@3bobo

Description

when I run train_classification.py, there is an error:

Traceback (most recent call last):
  File "train_classification.py", line 58, in <module>
    classifier = PointNetCls(k = num_classes, num_points = opt.num_points)
TypeError: __init__() got an unexpected keyword argument 'num_points'

I noticed that opt.num_points has been used in

dataset = PartDataset(root = 'shapenetcore_partanno_segmentation_benchmark_v0', classification = True, npoints = opt.num_points)

so I comment it and run again, but another error:
ValueError: Expected more than 1 value per channel when training, got input size [1, 512]
and this comes from :
x = F.relu(self.bn4(self.fc1(x)))

how to solve it? thanks for your help

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