Commit Graph

9097 Commits

Author SHA1 Message Date
Dave Pugmire
0a3fd2629f Add test file for corner case. 2021-08-03 15:33:51 -04:00
Dave Pugmire
4b0896bd8c Fix for corner case in particle advection. 2021-08-02 13:39:32 -04:00
Vicente Bolea
9007c97c4c Merge topic 'fix-lfs-default-url'
7ea282734 LFS: Set default url to the current origin url

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2532
2021-07-30 14:08:48 -04:00
Kenneth Moreland
822eb8f165 Merge topic 'copy-runtime-state'
624117963 Add RuntimeDeviceTracker::CopyState

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Li-Ta Lo <ollie@lanl.gov>
Merge-request: !2540
2021-07-29 10:37:52 -04:00
Kenneth Moreland
3b9e028a5e Merge topic 'deprecate-arrayhandle-getdeviceadapterid'
34615a985 Deprecate ArrayHandle::GetDeviceAdapterId

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Li-Ta Lo <ollie@lanl.gov>
Merge-request: !2534
2021-07-29 10:37:05 -04:00
Kenneth Moreland
6241179631 Add RuntimeDeviceTracker::CopyState
It is sometimes the case that you want to copy the state of one
`RuntimeDeviceTracker` to another. This is particularly the case when
creating threads in the control environment. Each thread has its own
copy of `RuntimeDeviceTracker`, so when you spawn a thread you probably
want to copy the state of the tracker from the calling thread.
2021-07-28 13:16:12 -06:00
Kenneth Moreland
34615a9858 Deprecate ArrayHandle::GetDeviceAdapterId
This method is a remenant of when `ArrayHandle` could only store data on
one device at a time. It is now capable of storing data on any number of
devices (as well as the host), so asking for "the" device no longer
makes sense. Thus, this method is deprecated in favor of
`ArrayHandle::IsOnDevice`.

This deprecation leads to fixing some older functionality that still
assumed data could only be on one device at a time.

Fixes #592.
2021-07-28 12:51:51 -06:00
Kenneth Moreland
bf6d6ca517 Merge topic 'shallow-array-copy'
1fb114172 Update code to use ArrayCopyShallowIfPossible
5c36eafe5 Add ArrayCopyShallowIfPossible

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Li-Ta Lo <ollie@lanl.gov>
Merge-request: !2529
2021-07-21 11:29:48 -04:00
Vicente Bolea
f34b432832 Merge topic 'fix-doxygen-docs'
9fe31c884 Doxygen: Update doxygen hosting URL

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2533
2021-07-16 17:31:46 -04:00
Vicente Adolfo Bolea Sanchez
9fe31c8848 Doxygen: Update doxygen hosting URL
Signed-off-by: Vicente Adolfo Bolea Sanchez <vicente.bolea@kitware.com>
2021-07-16 17:19:05 -04:00
Vicente Adolfo Bolea Sanchez
7ea282734a LFS: Set default url to the current origin url
Signed-off-by: Vicente Adolfo Bolea Sanchez <vicente.bolea@kitware.com>
2021-07-16 16:18:10 -04:00
Gunther Weber
1485af6e87 Merge topic 'fix/replace-stl-with-vtkm-exception'
f9eab2eee Replace STL exception in contour tree with VTKM exception

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <morelandkd@ornl.gov>
Merge-request: !2531
2021-07-16 12:23:08 -04:00
Gunther H. Weber
f9eab2eeec Replace STL exception in contour tree with VTKM exception 2021-07-15 14:00:23 -07:00
Kenneth Moreland
1fb1141723 Update code to use ArrayCopyShallowIfPossible
There were several places in the code that had to check the type of an
`UnknownArrayHandle` and conditionally get or copy that array. This code
is simplified by using `ArrayCopyShallowIfPossible`.
2021-07-15 08:53:52 -06:00
Kenneth Moreland
5c36eafe56 Add ArrayCopyShallowIfPossible
Often times you have an array of an unknown type (likely from a data set),
and you need it to be of a particular type (or can make a reasonable but
uncertain assumption about it being a particular type). You really just
want a shallow copy (a reference in a concrete `ArrayHandle`) if that is
possible.

`ArrayCopyShallowIfPossible` pulls an array of a specific type from an
`UnknownArrayHandle`. If the type is compatible, it will perform a shallow
copy. If it is not possible, a deep copy is performed to get it to the
correct type.

Fixes #572.
2021-07-15 08:52:07 -06:00
Gunther Weber
6c7a062b01 Merge topic 'contour-tree-performance-improvements'
851c32718 Clean-up 0f CopyArrayByIndices and CopyVecArrayByIndices helpers
89fc3be8f Changed comment style to avoid warning
17caf7f3a Fixed incorrect filename in CMakeLists.txt
c3b3c44eb Update CMakeLists.txt
b625ef7db Removed helper function for debugging
dffb7afbc Clean-up. Move functor class outside template.
51f737041 Clean-up. Move functor class outside template.
749232665 Added missing const qualifier
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <morelandkd@ornl.gov>
Merge-request: !2443
2021-07-14 13:04:06 -04:00
Gunther Weber
fa0ce37b96 Merge topic 'add/ct_iter_check'
ca86402f9 Provide additional debug info in case contour tree hangs
48d91b99f Throw exception if merge tree gets stuck in a loop
c7ea03ee2 Throw exception if contour tree gets stuck in a loop

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2420
2021-07-13 21:29:04 -04:00
Sujin Philip
c5b72c9d97 Merge topic 'fix-cuda-interop'
8d62bf128 Fix cuda-opengl interop

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <morelandkd@ornl.gov>
Merge-request: !2528
2021-07-13 10:48:25 -04:00
Kenneth Moreland
d2df97cc0b Merge topic 'fp-exceptions'
f883b5e03 Avoid divide by zero in rendering TriangleIntersections
ede775692 Allow for empty Z bounds in ResetToBounds
4c1514bb3 Fix divide by zero in CanvasRayTracer
83369ed95 Remove unused fields from Ortho2DRayGen
c1a790db2 Fix BIH split calculations for empty regions
9ce97352d Fix divide-by-zero in UnitTestCellInterpolate
e4ae3cee1 Avoid floating point exception in Orthonormalize
f74a2239e Break LUP factorization when invalid matrix found
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Matt Larsen <larsen30@llnl.gov>
Merge-request: !2527
2021-07-12 16:14:12 -04:00
Kenneth Moreland
f883b5e036 Avoid divide by zero in rendering TriangleIntersections 2021-07-12 11:23:24 -06:00
Kenneth Moreland
ede7756929 Allow for empty Z bounds in ResetToBounds
If the camera is not a 3D camera, then it might be the case that the
calling code has not set the bounds in the Z direction. Allow this to
happen as long as you are not using a 3D camera.
2021-07-12 10:57:19 -06:00
Kenneth Moreland
4c1514bb3a Fix divide by zero in CanvasRayTracer
The divide by zero happened when mapping a surface to a depth buffer.
Some rays terminated at the origin, which is a singularity in the
project matrix.

This might be indicative of a larger problem. Rays really shouldn't
terminate before the near plane.
2021-07-12 10:29:46 -06:00
Kenneth Moreland
83369ed95a Remove unused fields from Ortho2DRayGen
There were apparently some fields copy/pasted from the 3D version were
not used in the 2D version (probably because they had no meaning). In
one case, one was erroneously normalized, and could cause a floating
point exception.
2021-07-12 10:29:46 -06:00
Kenneth Moreland
c1a790db2d Fix BIH split calculations for empty regions
When computing the cost for splitting, if a regions was empty you would
get a floating point error when multiplying the (invalid) region bound
(inf or -inf) with the number of points (0). It would then check for NaN
costs and reset that. This worked but caused a floating point exception,
which is problematic for some users.

Instead, check for empty regions before computing the cost and reset the
cost that way.
2021-07-12 10:29:46 -06:00
Kenneth Moreland
9ce97352d9 Fix divide-by-zero in UnitTestCellInterpolate 2021-07-12 10:29:46 -06:00
Kenneth Moreland
e4ae3cee1b Avoid floating point exception in Orthonormalize 2021-07-12 10:29:46 -06:00
Kenneth Moreland
f74a2239eb Break LUP factorization when invalid matrix found
Singular matrices cannot be LUP factorized, so this condition is
detected and returned in a `valid` flag. However, when the detection
happened, the rest of the computation continued to happen. This could
lead to floating point exceptions, which some applications do not like.
So, when an invalid array is detected, return immediately.
2021-07-12 10:29:46 -06:00
Kenneth Moreland
6447b17303 Disable floating point exception traps when testing NaNs
Some functions are supposed to behave correctly when given a NaN. This
might only be valid if floation point exceptions are not trapped, so
disable trapping for these tests.
2021-07-12 10:29:45 -06:00
Kenneth Moreland
b01ca530b8 Turn on floating point exception trapping for GCC in tests
Some simulations trap floating point exceptions to ensure that their
code is working correctly, and we want VTK-m to work correctly in their
code. To check this, we want to turn on floating point exception
trapping in our test code. This is very implementation-specific, so for
now we are just turning it on for GCC. This will at least alert a
problem on some of the dashboards.
2021-07-12 10:29:37 -06:00
Sujin Philip
8d62bf1286 Fix cuda-opengl interop
1. Use cudaPerThreadStream instead of the default streams
2. Since there have been changes to ArrayHandle code, the API to create
ArrayHandle from a device pointer has changed.
2021-07-12 10:32:44 -04:00
Kenneth Moreland
80d622cd92 Merge topic 'unknown-array-better-allocate'
8d7cf2c85 Support all Allocate flags in UnknownArrayHandle

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Li-Ta Lo <ollie@lanl.gov>
Merge-request: !2522
2021-06-30 14:06:18 -04:00
Gunther H. Weber
851c327188 Clean-up 0f CopyArrayByIndices and CopyVecArrayByIndices helpers 2021-06-28 15:44:44 -07:00
Gunther H. Weber
89fc3be8fa Changed comment style to avoid warning 2021-06-28 15:44:44 -07:00
Gunther H. Weber
17caf7f3a4 Fixed incorrect filename in CMakeLists.txt 2021-06-28 15:44:44 -07:00
Gunther H. Weber
c3b3c44eb1 Update CMakeLists.txt 2021-06-28 15:44:44 -07:00
Gunther H. Weber
b625ef7dbd Removed helper function for debugging 2021-06-28 15:44:44 -07:00
Gunther H. Weber
dffb7afbcd Clean-up. Move functor class outside template. 2021-06-28 15:44:44 -07:00
Gunther H. Weber
51f737041b Clean-up. Move functor class outside template. 2021-06-28 15:44:44 -07:00
Gunther H. Weber
749232665b Added missing const qualifier 2021-06-28 15:44:44 -07:00
Gunther H. Weber
32dcd3d0c5 Refactor merging to be restricted to only common vertices 2021-06-28 15:44:44 -07:00
Gunther H. Weber
47cc80e42c Add missing ArrayRangeComputeTemplate.h include to avoid memory copy 2021-06-28 15:44:44 -07:00
Gunther H. Weber
f5b95fe42d Clean up/remove contour tree mesh worklets no longer used. 2021-06-28 15:44:43 -07:00
Gunther H. Weber
35da705571 Add missing contour tree mesh worklets to CMakeLists.txt 2021-06-28 15:44:43 -07:00
Gunther H. Weber
b2fd0f9178 Added missing VTKM_EXEC in CopyNeighborsToPackedArray worklet 2021-06-28 15:44:43 -07:00
Gunther H. Weber
608dec63e8 Disable debug output in UnitTestContourTreeUniformDistributed 2021-06-28 15:44:43 -07:00
Gunther H. Weber
4da3fb57e9 Improved merge by keeping track of insert position 2021-06-28 15:44:43 -07:00
Gunther H. Weber
1437a2e04f Use --vtkm-device instad of -d in test script 2021-06-28 15:44:43 -07:00
Gunther H. Weber
9ccde88d0f Commented out debug output/added comment. 2021-06-28 15:44:43 -07:00
Gunther H. Weber
9548ba5100 Add debug out and refactor for debugging 2021-06-28 15:44:43 -07:00
Gunther H. Weber
968ccfc351 Refactored ContourTreeMesh based on Ken Moreland's suggestions 2021-06-28 15:44:43 -07:00