Repository navigation
Correct bound check for axis aligned bounding box and use same formatting for printing cuda or cpu tensor - #6444
Merged
ssheorey merged 4 commits intoOct 24, 2023
Conversation
|
Thanks for submitting this pull request! The maintainers of this repository would appreciate if you could update the CHANGELOG.md based on your changes. |
Contributor
Author
saurabheights
force-pushed
the
khanduja/add_aabb_bounds_check
branch
from
October 22, 2023 21:08
9381e53 to
bfa6f46
Compare
saurabheights
force-pushed
the
khanduja/add_aabb_bounds_check
branch
from
October 22, 2023 21:10
bfa6f46 to
0afb67e
Compare
benjaminum
approved these changes
Oct 24, 2023
benjaminum
left a comment
Contributor
There was a problem hiding this comment.
Reviewable status: 0 of 4 files reviewed, all discussions resolved
saurabheights
added a commit
to saurabheights/Open3D
that referenced
this pull request
Nov 13, 2023
8 of 9 tasks
ssheorey
added a commit
that referenced
this pull request
Nov 14, 2023
* Change invalid values of min_bound and max_bound as done in legacy, related pr #6444 * Correct points length check when creating AABB from points. * Print min and max bound of AABB when printing AABB * Add brief docs for methods and variables, fix warning messages. * Fix AABB ToString() test --------- Co-authored-by: Sameer Sheorey <41028320+ssheorey@users.noreply.github.com>
saurabheights
commented
Dec 18, 2023
| if (IsCUDA() || !IsContiguous()) { | ||
| Tensor host_contiguous_tensor = Contiguous().To(Device("CPU:0")); | ||
| rc << host_contiguous_tensor.ToString(false, ""); | ||
| rc << host_contiguous_tensor.ToString(with_suffix, indent); |
Contributor
Author
There was a problem hiding this comment.
Sorry, I added a regression here. with_suffix should be set to false, else it will print suffix twice. once in inner call where tensor is moved to CPU and once in outer call.
Example -
o3d.core.Tensor.eye(n=4, dtype=o3d.core.Dtype.Float64, device=o3d.core.Device('cuda:0'))
[[1 0 0 0],
[0 1 0 0],
[0 0 1 0],
[0 0 0 1]]
Tensor[shape={4, 4}, stride={4, 1}, Float64, CPU:0, 0x561c38e195d0]
Tensor[shape={4, 4}, stride={4, 1}, Float64, CUDA:0, 0x302000000]
I will address this in my next PR.
saurabheights
added a commit
to saurabheights/Open3D
that referenced
this pull request
Jan 11, 2024
4 of 9 tasks
ssheorey
pushed a commit
that referenced
this pull request
Jan 19, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Type
Motivation and Context
A. Cuda tensor do not use same formatting as tensor in cpu.
B. Axis aligned Bounding Box can be constructed with invalid bounds and causes aberrant behaviour.
Checklist:
python util/check_style.py --applyto apply Open3D code styleto my code.
updated accordingly.
results (e.g. screenshots or numbers) here.
Description
Printing cuda tensor with same formatting variables
with_suffixandindentas passed in calling method is self-explanatory.For #6436, In case min bound is larger than amx bound in at least one axis, the min bound and max bound values are swapped in those axis/axes with a warning, reporting user of the change made.
This change isβ