Summary:
Converts the directory specified to use the Ruff formatter in pyfmt
ruff_dog
If this diff causes merge conflicts when rebasing, please run
`hg status -n -0 --change . -I '**/*.{py,pyi}' | xargs -0 arc pyfmt`
on your diff, and amend any changes before rebasing onto latest.
That should help reduce or eliminate any merge conflicts.
allow-large-files
Reviewed By: bottler
Differential Revision: D66472063
fbshipit-source-id: 35841cb397e4f8e066e2159550d2f56b403b1bef
Summary:
Applies new import merging and sorting from µsort v1.0.
When merging imports, µsort will make a best-effort to move associated
comments to match merged elements, but there are known limitations due to
the diynamic nature of Python and developer tooling. These changes should
not produce any dangerous runtime changes, but may require touch-ups to
satisfy linters and other tooling.
Note that µsort uses case-insensitive, lexicographical sorting, which
results in a different ordering compared to isort. This provides a more
consistent sorting order, matching the case-insensitive order used when
sorting import statements by module name, and ensures that "frog", "FROG",
and "Frog" always sort next to each other.
For details on µsort's sorting and merging semantics, see the user guide:
https://usort.readthedocs.io/en/stable/guide.html#sorting
Reviewed By: bottler
Differential Revision: D35553814
fbshipit-source-id: be49bdb6a4c25264ff8d4db3a601f18736d17be1
Summary:
The following snippet should work in more cases.
point_cloud = Pointclouds(
[pcl.points_packed() for pcl in point_clouds],
features=[pcl.features_packed() for pcl in point_clouds],
)
We therefore allow features and normals inputs to be lists which contain some (but not all) Nones.
The initialization of a Pointclouds from empty data is also made a bit better now at working out how many feature channels there are.
Reviewed By: davnov134
Differential Revision: D31795089
fbshipit-source-id: 54bf941ba80672d699ffd5ac28927740e830f8ab
Summary: Update all FB license strings to the new format.
Reviewed By: patricklabatut
Differential Revision: D33403538
fbshipit-source-id: 97a4596c5c888f3c54f44456dc07e718a387a02c
Summary: Function to join a list of pointclouds as a batch similar to the corresponding function for Meshes.
Reviewed By: bottler
Differential Revision: D33145906
fbshipit-source-id: 160639ebb5065e4fae1a1aa43117172719f3871b
Summary: As subj. Tests corrected accordingly. Also changed the test to provide a bit better diagnostics.
Reviewed By: bottler
Differential Revision: D32879498
fbshipit-source-id: 0a852e4a13dcb4ca3e54d71c6b263c5d2eeaf4eb
Summary: New function to randomly subsample Pointclouds to a maximum size.
Reviewed By: nikhilaravi
Differential Revision: D30936533
fbshipit-source-id: 789eb5004b6a233034ec1c500f20f2d507a303ff
Summary:
Tidy uses of `torch.device` in `Pointclouds`:
- Allow `str` or `torch.device` in `Pointclouds.to()` method
- Consistently use `torch.device` for internal type
- Fix comparison of devices
Reviewed By: nikhilaravi
Differential Revision: D28970221
fbshipit-source-id: 3ca7104d4c0d9b20b0cff4f00e3ce931c5f1528a
Summary:
It is common when trying things out to want to move a whole mesh or point cloud by the same amount. Here we allow the offset functions to broadcast.
Also add a sanity check to join_meshes_as_scene which it is easy to call wrongly.
Reviewed By: nikhilaravi
Differential Revision: D25980593
fbshipit-source-id: cdf1568e1317e3b81ad94ed4e608ba7eef81290b
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