pointnet icon indicating copy to clipboard operation
pointnet copied to clipboard

module 'utils'

Open sank96 opened this issue 4 years ago • 13 comments

When I try to run the notebook

AttributeError                            Traceback (most recent call last)
<ipython-input-16-6f9310cafa62> in <module>
     12 print('######### Dataset class created #########')
     13 print('Number of images: ', len(dset))
---> 14 print('Sample image shape: ', dset[0]['image'].shape)
     15 #print('Sample image points categories', dset[0]['category'], end='\n\n')
     16 

<ipython-input-15-a0ffe3b5dad8> in __getitem__(self, idx)
     36         category = self.files[idx]['category']
     37         with open(img_path, 'r') as f:
---> 38             image1 = read_pts(f)
     39         with open(category, 'r') as f:
     40             category1 = read_seg(f)

<ipython-input-13-6a351433de44> in read_pts(file)
      3 def read_pts(file):
      4     verts = np.genfromtxt(file)
----> 5     return utils.cent_norm(verts)
      6     #return verts
      7 

AttributeError: module 'utils' has no attribute 'cent_norm'

Initially I had this error

ModuleNotFoundError: No module named 'utils'

So i installed this package but I think that it is not the correct one. Which one do I have to install?

sank96 avatar Dec 03 '20 15:12 sank96

I had the same problem. module 'utils' has no attribute 'cent_norm'

st5714 avatar Dec 15 '20 20:12 st5714

Hi @mett96, @st5714,

Indeed, it doesn't work. Thank you for point it out, I will fix the segmentation notebook so it works with the update version of code. In the meanwhile, you can check out the classification notebook. There is no such a problem for this one.

Thanks again, Nikita

nikitakaraevv avatar Dec 17 '20 19:12 nikitakaraevv

Did this problem ever end up getting fixed?

normalusername1 avatar Dec 31 '20 17:12 normalusername1

Wondering too

mserouar avatar Jan 15 '21 13:01 mserouar

Hi Nikita,

Spent a good chunk of time running through your classification model with great results and hoping to do the same with your part segmentation model. Have you had the chance to fix this issue? Would be great to implement your model!

Thanks,

Michael

michaelhasey avatar Jul 22 '21 21:07 michaelhasey

Hi @mett96, @st5714,

Indeed, it doesn't work. Thank you for point it out, I will fix the segmentation notebook so it works with the update version of code. In the meanwhile, you can check out the classification notebook. There is no such a problem for this one.

Thanks again, Nikita

Hi @nikitakaraevv ,I also had the same problem when I ran the PointNetSeg. It would be cool if the model could be implemented. Looking forward to it.

bwlstart avatar Feb 28 '22 12:02 bwlstart

i solve this problem by replacing 'utils.cent_norm(verts)' to 'Normalize()(verts)' which is in utils.py

Largehare avatar Jul 03 '22 10:07 Largehare

i solve this problem by replacing 'utils.cent_norm(verts)' to 'Normalize()(verts)' which is in utils.py

Did you end up being able to use this code for PointNetSeg? If you did it would be great to know how you have solved the other issues - thank you!

scho419 avatar Sep 15 '22 00:09 scho419

i solve this problem by replacing 'utils.cent_norm(verts)' to 'Normalize()(verts)' which is in utils.py

Did you end up being able to use this code for PointNetSeg? If you did it would be great to know how you have solved the other issues - thank you!

Yes, I successfully run the code in the end. But I have forgot what other issues I had met.

Largehare avatar Sep 15 '22 12:09 Largehare

i solve this problem by replacing 'utils.cent_norm(verts)' to 'Normalize()(verts)' which is in utils.py

Did you end up being able to use this code for PointNetSeg? If you did it would be great to know how you have solved the other issues - thank you!

Yes, I successfully run the code in the end. But I have forgot what other issues I had met.

Hi, I'm a freshman in the school. So I didn't know how to implement point cloud code. I would be very thankful if you could send me your code about pointnetSeg.ipynb in the project :) And the structure tree of the project (put the data to where and which datasets your used)

Bailey-24 avatar Sep 30 '22 01:09 Bailey-24

i solve this problem by replacing 'utils.cent_norm(verts)' to 'Normalize()(verts)' which is in utils.py

Did you end up being able to use this code for PointNetSeg? If you did it would be great to know how you have solved the other issues - thank you!

Yes, I successfully run the code in the end. But I have forgot what other issues I had met.

Hi, I'm a freshman in the school. So I didn't know how to implement point cloud code. I would be very thankful if you could send me your code about pointnetSeg.ipynb in the project :) And the structure tree of the project (put the data to where and which datasets your used)

Here is the link:https://www.kaggle.com/code/largehare/pointnetseg/notebook. You can have a try.

Largehare avatar Sep 30 '22 04:09 Largehare

Thank you. I'm trying.

Bailey-24 avatar Sep 30 '22 07:09 Bailey-24

Thank you. I change the dir of the dataset, and it works. Thanks again.

Bailey-24 avatar Oct 04 '22 02:10 Bailey-24