learning3d 0.0.4__py3-none-any.whl → 0.0.6__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -184,13 +184,14 @@ class ModelNet40Data(Dataset):
184
184
  self,
185
185
  train=True,
186
186
  num_points=1024,
187
- root_dir=None,
187
+ download=False,
188
+ root_dir='./',
188
189
  randomize_data=False,
189
190
  use_normals=False
190
191
  ):
191
192
  super(ModelNet40Data, self).__init__()
192
193
  self.root_dir = root_dir
193
- if root_dir is not None: download_modelnet40(root_dir=root_dir)
194
+ if download: download_modelnet40(root_dir=root_dir)
194
195
  self.data, self.labels = load_data(root_dir, train, use_normals)
195
196
  if not train: self.shapes = self.read_classes_ModelNet40()
196
197
  self.num_points = num_points
@@ -225,15 +226,15 @@ class ModelNet40Data(Dataset):
225
226
 
226
227
 
227
228
  class ClassificationData(Dataset):
228
- def __init__(self, data_class=ModelNet40Data()):
229
+ def __init__(self, data_class=ModelNet40Data, root_dir='./'):
229
230
  super(ClassificationData, self).__init__()
230
- self.set_class(data_class)
231
+ self.set_class(data_class, root_dir)
231
232
 
232
233
  def __len__(self):
233
234
  return len(self.data_class)
234
235
 
235
- def set_class(self, data_class):
236
- self.data_class = data_class
236
+ def set_class(self, data_class, root_dir):
237
+ self.data_class = data_class(root_dir=root_dir)
237
238
 
238
239
  def get_shape(self, label):
239
240
  try:
@@ -246,13 +247,13 @@ class ClassificationData(Dataset):
246
247
 
247
248
 
248
249
  class RegistrationData(Dataset):
249
- def __init__(self, algorithm, data_class=ModelNet40Data(), partial_source=False, partial_template=False, noise=False, additional_params={}):
250
+ def __init__(self, algorithm, root_dir='./', data_class=ModelNet40Data, partial_source=False, partial_template=False, noise=False, additional_params={}):
250
251
  super(RegistrationData, self).__init__()
251
252
  available_algorithms = ['PCRNet', 'PointNetLK', 'DCP', 'PRNet', 'iPCRNet', 'RPMNet', 'DeepGMR']
252
253
  if algorithm in available_algorithms: self.algorithm = algorithm
253
254
  else: raise Exception("Algorithm not available for registration.")
254
255
 
255
- self.set_class(data_class)
256
+ self.set_class(data_class, root_dir)
256
257
  self.partial_template = partial_template
257
258
  self.partial_source = partial_source
258
259
  self.noise = noise
@@ -282,8 +283,8 @@ class RegistrationData(Dataset):
282
283
  def __len__(self):
283
284
  return len(self.data_class)
284
285
 
285
- def set_class(self, data_class):
286
- self.data_class = data_class
286
+ def set_class(self, data_class, root_dir):
287
+ self.data_class = data_class(root_dir=root_dir)
287
288
 
288
289
  def __getitem__(self, index):
289
290
  template, label = self.data_class[index]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: learning3d
3
- Version: 0.0.4
3
+ Version: 0.0.6
4
4
  Summary: Learning3D: A Modern Library for Deep Learning on 3D Point Clouds Data
5
5
  Author-email: Vinit Sarode <vinitsarode5@gmail.com>
6
6
  Project-URL: Homepage, https://github.com/vinits5/learning3d
@@ -1,6 +1,6 @@
1
1
  learning3d/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
2
  learning3d/data_utils/__init__.py,sha256=iYAVh0FThnVlG42QIgmDYrC3NGVYuzKX8s1oRqAI1YU,261
3
- learning3d/data_utils/dataloaders.py,sha256=XqlVl-IumBxW1woA8GtgCgEMNhrjCgyaAtKhYxPxnTg,14703
3
+ learning3d/data_utils/dataloaders.py,sha256=s4eNc3ISqSutScvXkVZ-6PMY0-Bu5Br_N7XUhPAFjHs,14813
4
4
  learning3d/data_utils/user_data.py,sha256=ADDGeCUCr6TcXhcxvAFncIeLO71xoRHYi4H418ktvQs,4828
5
5
  learning3d/examples/test_dcp.py,sha256=o1hgl22b2xhqqYe4_k7NlNo3-rIMmSzzssCI74DCfoE,5606
6
6
  learning3d/examples/test_deepgmr.py,sha256=pb-gRE6YLLaPFmiBXQjaE-B-J314QY4RkNwLHx65bcU,5597
@@ -73,8 +73,8 @@ learning3d/utils/pointconv_util.py,sha256=kJxGztai7X15YsGuorMOc50SPtj_k1yfkP4XCT
73
73
  learning3d/utils/ppfnet_util.py,sha256=HEoxkgUBlawKZLWspfQm3caWUyAMIrW-ECtStNYbe2Y,7989
74
74
  learning3d/utils/svd.py,sha256=yCYQt2SKqeIzCBnBEr_8xFR79m4fIoNVFnp77epn1dM,1936
75
75
  learning3d/utils/transformer.py,sha256=UDgJvnh7ekWyijaAn-a3ckeFeMxlK_chXzWlhAGDiPM,8974
76
- learning3d-0.0.4.dist-info/LICENSE,sha256=3qY3_NeQIvalbLlsHFtOfuUKjs_U2k6u7rf6YVx6ac0,1098
77
- learning3d-0.0.4.dist-info/METADATA,sha256=zC24gcn1X2bakXZ3q0phrhkXyJXQhkyOWbDA6KncVJk,15813
78
- learning3d-0.0.4.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
79
- learning3d-0.0.4.dist-info/top_level.txt,sha256=nTmYW8NhbNV1_15DGNpl_OvvSFtQP98sy3qrrHr0eLo,11
80
- learning3d-0.0.4.dist-info/RECORD,,
76
+ learning3d-0.0.6.dist-info/LICENSE,sha256=3qY3_NeQIvalbLlsHFtOfuUKjs_U2k6u7rf6YVx6ac0,1098
77
+ learning3d-0.0.6.dist-info/METADATA,sha256=S8XK9N6x5U7C6FqGVQwvAhOkegpGd0M1qLlvD2GvAwI,15813
78
+ learning3d-0.0.6.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
79
+ learning3d-0.0.6.dist-info/top_level.txt,sha256=nTmYW8NhbNV1_15DGNpl_OvvSFtQP98sy3qrrHr0eLo,11
80
+ learning3d-0.0.6.dist-info/RECORD,,