mirror of
https://github.com/facebookresearch/pytorch3d.git
synced 2025-12-21 06:40:35 +08:00
align_corners and padding for TexturesUV
Summary: Allow, and make default, align_corners=True for texture maps. Allow changing the padding_mode and set the default to be "border" which produces more logical results. Some new documentation. The previous behavior corresponds to padding_mode="zeros" and align_corners=False. Reviewed By: gkioxari Differential Revision: D23268775 fbshipit-source-id: 58d6229baa591baa69705bcf97471c80ba3651de
This commit is contained in:
committed by
Facebook GitHub Bot
parent
d0cec028c7
commit
e25ccab3d9
@@ -411,11 +411,11 @@ class TestPointclouds(TestCaseMixin, unittest.TestCase):
|
||||
new_clouds = clouds.detach()
|
||||
|
||||
for cloud in new_clouds.points_list():
|
||||
self.assertTrue(cloud.requires_grad == False)
|
||||
self.assertFalse(cloud.requires_grad)
|
||||
for normal in new_clouds.normals_list():
|
||||
self.assertTrue(normal.requires_grad == False)
|
||||
self.assertFalse(normal.requires_grad)
|
||||
for feats in new_clouds.features_list():
|
||||
self.assertTrue(feats.requires_grad == False)
|
||||
self.assertFalse(feats.requires_grad)
|
||||
|
||||
for attrib in [
|
||||
"points_packed",
|
||||
@@ -425,9 +425,7 @@ class TestPointclouds(TestCaseMixin, unittest.TestCase):
|
||||
"normals_padded",
|
||||
"features_padded",
|
||||
]:
|
||||
self.assertTrue(
|
||||
getattr(new_clouds, attrib)().requires_grad == False
|
||||
)
|
||||
self.assertFalse(getattr(new_clouds, attrib)().requires_grad)
|
||||
|
||||
self.assertCloudsEqual(clouds, new_clouds)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user