Commit Graph

8586 Commits

Author SHA1 Message Date
Kenneth Moreland
fa4da95eb2 Add changelog for copying UnknownArrayHandle 2021-02-02 17:34:12 -07:00
Kenneth Moreland
1faed3712e Remove the use of ResetTypes for ArrayCopy
It used to be the case where you needed to call `ResetTypes` on a
`VariantArrayHandle` before using `ArrayCopy` to limit the types it gets
compiled for. However, there is now a general form for
`UnknownArrayHandle`, so `ResetTypes` no longer does anything useful in
this case. Remove the use of that.
2021-02-02 17:34:08 -07:00
Kenneth Moreland
ad7033684f Change ArrayCopy of UnknownArrayHandle to limit types
Rather than copy every type to every other type, only copy for the same
base type or copy to/from FloatDefault. This should reduce the amount of
code generated by a lot.

This reduces the size of the .o for ArrayCopy.cxx on my mac from
21MB to 7.7MB.
2021-02-02 17:33:08 -07:00
Kenneth Moreland
916a01d7b9 Add general ArrayCopy between UnknownArrayHandles
Add an overload of `ArrayCopy` that takes `UnknownArrayHandle`s and
copies them for (almost) any `ArrayHandle` type.

The code uses `CastAndCallWithExtractedArray` to reduce the total number
of copy conditions to about 100, which are all precompiled into the
library. On a debug build on my mac, this creates a .o file of 21MB.
That's not great, but not terrible. Hopefully, this can be used to
consolidate copy implementations elsewhere.
2021-02-02 17:33:08 -07:00
Kenneth Moreland
26ea2ab420 Break circular dependency of ArrayCopy.h and UnknownArrayHandle.h
The circular dependency came from UnknownArrayHandle.h needing
VTKmDefaultTypes.h, which needed all the cell set types. Some of those
cell sets used ArrayCopy in templated functions. Changed those functions
to directly deep copy the ArrayHandle.
2021-02-02 17:33:08 -07:00
Kenneth Moreland
990cc9ecea Test copying UnknownArrayHandle 2021-02-02 17:33:08 -07:00
Gunther Weber
eb5e522893 Merge topic 'contourtree_debug'
7ed0cd156 Fix deprecation warning
c9af28756 Fix ValueType error in pre-split data read
cea117323 Reverse error check in ContourTreeMaker
5005b5d44 Updated ContourTreeMesh::DebugPrint / ContourTreeMaker::DebugPrintt to use per-call build guards

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2394
2021-02-02 18:16:49 -05:00
Gunther H. Weber
7ed0cd1562 Fix deprecation warning 2021-02-02 13:46:14 -08:00
Oliver Ruebel
c9af28756c Fix ValueType error in pre-split data read 2021-02-02 13:46:01 -08:00
Oliver Ruebel
cea1173233 Reverse error check in ContourTreeMaker 2021-02-02 13:46:01 -08:00
Oliver Ruebel
5005b5d44a Updated ContourTreeMesh::DebugPrint / ContourTreeMaker::DebugPrintt to use per-call build guards 2021-02-02 13:44:50 -08:00
Gunther Weber
8ebd889732 Merge topic 'add-contour-tree-unit-tests'
c59d8b25b Use test_equal_ArrayHandles instead of custom functions ArraysEqual
06ab386a0 Added test for combinining contour tree meshes
3d5adf335 Re-enabled tests with external files (and added required files to Git LFS)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <kmorel@sandia.gov>
Merge-request: !2344
2021-02-01 16:55:29 -05:00
Kenneth Moreland
76634d167e Merge topic 'deprecate-arrayhandle-shrink'
34412ff29 Deprecate ArrayHandle::Shrink
eb90a6080 Update documentation for Storage

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2392
2021-02-01 16:07:22 -05:00
Kenneth Moreland
6cf86d30e4 Merge topic 'new-instance-float'
880d26d60 Add test for UnknownArrayHandle::NewInstanceFloatBasic
d51fdaddf Add UnknownArrayHandle::NewInstanceFloatBasic

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Dave Pugmire <dpugmire@gmail.com>
Merge-request: !2395
2021-02-01 15:58:29 -05:00
Kenneth Moreland
880d26d60a Add test for UnknownArrayHandle::NewInstanceFloatBasic 2021-02-01 10:24:13 -07:00
Kenneth Moreland
d51fdaddf8 Add UnknownArrayHandle::NewInstanceFloatBasic
This provides the ability to convert an array handle of an unknown value
type to an array handle that has `vtkm::FloatDefault` as its base
component type. Thus subsequently lets you pull the components as
`vtkm::FloatDefault` without having to worry about type conflicts.
2021-02-01 09:34:08 -07:00
Kenneth Moreland
34412ff298 Deprecate ArrayHandle::Shrink
This method has been subsumed by Allocate with vtkm::CopyFlag::On.
2021-02-01 08:07:40 -07:00
Gunther H. Weber
c59d8b25b1 Use test_equal_ArrayHandles instead of custom functions ArraysEqual 2021-01-29 11:33:25 -08:00
Gunther H. Weber
06ab386a03 Added test for combinining contour tree meshes 2021-01-29 09:45:13 -08:00
Gunther H. Weber
3d5adf335d Re-enabled tests with external files (and added required files to Git LFS) 2021-01-29 09:45:13 -08:00
Gunther Weber
4b93ce8fda Merge topic 'fix-typos'
239adf598 Fix typos in functor names for contour tree

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <kmorel@sandia.gov>
Merge-request: !2393
2021-01-29 11:53:45 -05:00
Gunther H. Weber
239adf5980 Fix typos in functor names for contour tree 2021-01-28 14:29:45 -08:00
Kenneth Moreland
eb90a6080c Update documentation for Storage 2021-01-28 14:37:10 -07:00
Gunther Weber
7011cb8794 Merge topic 're-add-mc-tests'
5d8a67eff Re-enable marching cubes unit tests for disitrbuted contour tree

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2391
2021-01-28 16:27:52 -05:00
Gunther H. Weber
5d8a67eff1 Re-enable marching cubes unit tests for disitrbuted contour tree 2021-01-28 11:51:42 -08:00
Gunther Weber
32a25a4b05 Merge topic 'test-contour-tree-augmented-mc'
0183db685 Split array access into separate lines and add VTKM_ASSERT
0a33737ea Re-enable unit tests for ContourTreeUniformAugmentedFilter

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <kmorel@sandia.gov>
Merge-request: !2390
2021-01-28 11:43:59 -05:00
Gunther H. Weber
0183db6854 Split array access into separate lines and add VTKM_ASSERT 2021-01-27 19:31:56 -08:00
Gunther H. Weber
0a33737eae Re-enable unit tests for ContourTreeUniformAugmentedFilter 2021-01-26 20:56:55 -08:00
Kenneth Moreland
399e358efa Merge topic 'runaway-deprecate-suppress'
8b133288c Fix deprecation warnings
b085cde35 Fix runaway deprecation suppression
3f5193d23 Consolidate getting a scalar field array

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Sujin Philip <sujin.philip@kitware.com>
Merge-request: !2387
2021-01-26 10:59:48 -05:00
Kenneth Moreland
8b133288ce Fix deprecation warnings
There was an error that caused deprecation warnings in VTK-m to be
suppressed, which meant that many uses of deprecated features went
unnoticed. This fixes those deprecation warnings.

The majority of the warnings were caused by the use of the deprecated
`Cast`, `CopyTo`, and `ResetTypes` methods of `UnknownArrayHandle` (or
`VariantArrayHandle`). Both `Cast` and `CopyTo` have been subsumed by
`AsArrayHandle` (to make the functionality more clear). `ResetTypes` now
requires a second template argument to define the storage types to try.

Also fixed some issues with `SerializableField` being deprecated.
This class is no longer necessary because `Field` can now be directly
serialized.
2021-01-26 07:56:39 -07:00
Kenneth Moreland
b085cde358 Fix runaway deprecation suppression
Field.h had a runaway deprecation suppression where the pragmas to
suppress deprecation warnings were turned on but not properly turned
off. This caused deprecation warnings to be turned off for anything
including Field.h (directly or indirectly), and consequently lots of use
of deprecated features went unnoticed.
2021-01-25 15:25:12 -07:00
Kenneth Moreland
3f5193d231 Consolidate getting a scalar field array
There are several places in the ray casting library that require
operating on a field that we know is a scalar field. Previously, these
were all independently cast to an uncertain array of the limited types.
Rather than have independent calls everywere, make a consolidated
function that does the same operation for everyone.

This fixes an issue with using a deprecated version of a method. It also
makes it possible to quickly change types in the future.
2021-01-25 15:25:11 -07:00
Kenneth Moreland
49ad0152d7 Merge topic 'fix_cuda_build'
c6c449246 Fix CUDA build for logistic map example.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <kmorel@sandia.gov>
Merge-request: !2386
2021-01-25 17:22:47 -05:00
Nick Thompson
c6c4492469 Fix CUDA build for logistic map example. 2021-01-19 15:20:58 -05:00
Nick Thompson
18a6b12509 Merge topic 'logistic'
61522fde7 Add #includes and explicitly identify the field name.
1bad28a3e Logistic map as an example of how to use the ImageWriter.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Nickolas Davis <nadavi@sandia.gov>
Merge-request: !2385
2021-01-19 14:42:42 -05:00
Nick Thompson
61522fde7b Add #includes and explicitly identify the field name. 2021-01-19 08:13:35 -05:00
Nick Thompson
1bad28a3ec Logistic map as an example of how to use the ImageWriter. 2021-01-16 15:13:33 -05:00
Li-Ta Lo
e7cf3d784a Merge topic 'hdf5_image_io'
081f8aaea reformat if statements, add comments on the HDF5 macros
31aa46706 Merge branch 'master' into hdf5_image_io
e65c0713b move #include of hdf5.h into .cxx files
ff0b8fd0b changed to CMake files based on Robert's feedback
ca0ce4de7 Merge branch 'master' into hdf5_image_io
23a95f864 exclude header files from install check when it is not enabled
d81f08eed correct copyright mesage
fb6c9afe7 uncomment ubuntu1805_cuda image
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Li-Ta Lo <ollie@lanl.gov>
Acked-by: Robert Maynard <robert.maynard@kitware.com>
Merge-request: !2371
2021-01-16 09:26:15 -05:00
Li-Ta Lo
081f8aaea8 reformat if statements, add comments on the HDF5 macros 2021-01-15 15:05:52 -07:00
Kenneth Moreland
84657e6ea7 Merge topic 'field-holds-unknownarrayhandle'
3a7ba1d56 Fix deprecation warning in MSVC
11a4c9867 Change Field to hold UnknownArrayHandle rather than VariantArrayHandle

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Sujin Philip <sujin.philip@kitware.com>
Merge-request: !2298
2021-01-15 13:45:49 -05:00
Li-Ta Lo
31aa467068 Merge branch 'master' into hdf5_image_io 2021-01-15 09:25:18 -07:00
Li-Ta Lo
e65c0713b8 move #include of hdf5.h into .cxx files 2021-01-15 09:12:52 -07:00
Kenneth Moreland
3a7ba1d569 Fix deprecation warning in MSVC
MSVC tends to give deprecation warnings in templated methods that are
used with deprecated classes rather than where the deprecated thing was
declared. That makes it annoyingly hard to supress them to implement
support of deprecated items.
2021-01-14 17:01:23 -07:00
Kenneth Moreland
11a4c9867e Change Field to hold UnknownArrayHandle rather than VariantArrayHandle
The `VariantArrayHandle` will soon be deprecated for its replacement of
`UnknownArrayHandle`. Thus, `Field` and related classes should start
using the new `UnknownArrayHandle`.
2021-01-14 17:01:22 -07:00
Li-Ta Lo
ff0b8fd0bb changed to CMake files based on Robert's feedback 2021-01-14 14:23:05 -07:00
Kenneth Moreland
30b8a31a58 Merge topic 'invalid-arrayhandle'
63d32a863 Fix compile error from invalid `ArrayHandle`

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Robert Maynard <robert.maynard@kitware.com>
Merge-request: !2384
2021-01-14 16:15:23 -05:00
Li-Ta Lo
ca0ce4de7b Merge branch 'master' into hdf5_image_io 2021-01-14 14:08:00 -07:00
Kenneth Moreland
63d32a863e Fix compile error from invalid ArrayHandle
The compile error happened from incompatible code changes between !2349
and !2374. The former removed the ability to use non-`Vec` values in
`ArrayHandleSOA`. The latter tried to create such an `ArrayHandle`
inside a template function that was called with the SOA storage.
2021-01-14 13:12:57 -07:00
Li-Ta Lo
bbba2a1967 Merge topic 'add_hdf5_to_ubuntu_1804_base_image'
7c94ebf2e Add HDF5 to Ubuntu 18.04/base image

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2378
2021-01-14 13:08:09 -05:00
Kenneth Moreland
a6edc832da Merge topic 'soa-array-default'
cecd81d5d Add types appropriate for Ascent
865855ea0 Add changelog for making ArrayHandleSOA a default array
50ff9c22a Add support of `ArrayHandleSOA` as a default storage type
bc09a9cd1 Add precompiled versions of `ArrayRangeCompute` for `ArrayHandleSOA`
77f9ae653 Support `ArrayHandleSOA` only for `Vec` value types

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Robert Maynard <robert.maynard@kitware.com>
Merge-request: !2349
2021-01-14 12:40:58 -05:00