git.haldean.org symrep / da73b1f
fix point cloud test Will Haldean Brown 4 years ago
1 changed file(s) with 3 addition(s) and 2 deletion(s). Raw diff Collapse all Expand all
8989
9090 def test_sphere(self):
9191 n = symrep.solids.sphere(symrep.const(2))
92 cloud = list(symrep.solids.to_pointcloud(
93 n, -2. * np.ones(3), 2 * np.ones(3), 500))
92 cloud = list(symrep.solids.sample_solid(
93 n, -2. * np.ones(3), 2 * np.ones(3),
94 symrep.solids.is_inside, 500))
9495 self.assertEqual(len(cloud), 500)
9596 for pt in cloud:
9697 self.assertLessEqual(np.linalg.norm(pt[:3]), 2.)