Commit Graph

7935 Commits

Author SHA1 Message Date
Kenneth Moreland
c802adcbeb Add support for CastAndCallVariableVecField in FilterField
The `FilterField` class provides convenience functions for subclasses to
determine the `ArrayHandle` type for scalar and vector fields. However, you
needed to know the specific size of vectors. For filters that support an
input field of any type, a new form, `CastAndCallVariableVecField` has been
added. This calls the underlying functor with an `ArrayHandleRecombineVec`
of the appropriate component type.

The `CastAndaCallVariableVecField` method also reduces the number of
instances created by having a float fallback for any component type that
does not satisfy the field types.
2023-05-22 10:14:59 -06:00
Kenneth Moreland
bb9e7a0d6f Handle any Vec size in VTKDataSetReader
The legacy VTK file reader previously only supported a specific set of Vec
lengths (i.e., 1, 2, 3, 4, 6, and 9). This is because a basic array
handle has to have the vec length compiled in. However, the new
`ArrayHandleRuntimeVec` feature is capable of reading in any vec-length
and can be leveraged to read in arbitrarily sized vectors in field
arrays.
2023-05-22 06:19:11 -06:00
Kenneth Moreland
2cc2205218 Merge topic 'composite-vectors-any-size'
b59580bb8 Allow CompositeVectors filter to build any size vector
a8b4e5a62 Add GetNumberOfActiveFields method to FilterField

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !3063
2023-05-18 16:28:39 -04:00
Kenneth Moreland
fb8e3d7ce7 Merge topic 'runtime-vec-info'
5bdd3c7bc Move ArrayHandleRuntimeVec metadata to a separate class

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Li-Ta Lo <ollie@lanl.gov>
Merge-request: !3062
2023-05-17 15:45:20 -04:00
Li-Ta Lo
fdf7aaece7 Merge topic 'rendering_cpp_cleanup'
ee9c78ca9 Merge branch 'master' into rendering_cpp_cleanup
d05025ce8 simplify comment
066e6a696 I think this is the proper way doing PIMPL
6e75be33e unique_ptr know if itself is valid
50a9efc2f use rvalue ref for parameter
61c002072 cleanup C++ usage, use unique_ptr for PIMPL

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <morelandkd@ornl.gov>
Merge-request: !3057
2023-05-17 11:18:39 -04:00
Kenneth Moreland
ae908c7129 Merge topic 'fix-iterator-operator'
09c0139b4 Fix operator for IteratorFromArrayPortal

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Li-Ta Lo <ollie@lanl.gov>
Merge-request: !3035
2023-05-16 19:03:22 -04:00
Gunther Weber
149a6c3a29 Merge topic 'release-deadlock'
58fc4d826 Fix potential deadlock in distributed contour tree

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !3024
2023-05-16 17:02:28 -04:00
Kenneth Moreland
b59580bb82 Allow CompositeVectors filter to build any size vector
Using the new `ArrayHandleRuntimeVec` feature, we can construct an array
with any vec sized value.
2023-05-16 12:39:40 -06:00
Kenneth Moreland
5bdd3c7bc2 Move ArrayHandleRuntimeVec metadata to a separate class
Originally, the metadata structure used by the `ArrayHandleRuntimeVec`
storage was a nested class of its `Storage`. But the `Storage` is
templated on the component type, and the metadata object is the same
regardless. In addition to the typical minor issue of having the
compiler create several identical classes, this caused problems when
pulling arrays from equivalent but technically different C types (for
example, `long` is the same as either `int` or `long long`).
2023-05-16 12:39:40 -06:00
Kenneth Moreland
a8b4e5a629 Add GetNumberOfActiveFields method to FilterField 2023-05-16 12:39:40 -06:00
Kenneth Moreland
09c0139b4e Fix operator for IteratorFromArrayPortal
There was an error in `operator-=` for `IteratorFromArrayPortal` that went
by unnoticed. The operator is fixed and regression tests for the operators
has been added.
2023-05-16 09:31:17 -06:00
Li-Ta Lo
ee9c78ca94 Merge branch 'master' into rendering_cpp_cleanup 2023-05-16 09:25:58 -06:00
Kenneth Moreland
8ef2c588a0 Merge topic 'unknown-runtime-vec-new-instance'
3c1afe53d Fix new instances of ArrayHandleRuntimeVec in UnknownArrayHandle

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Li-Ta Lo <ollie@lanl.gov>
Merge-request: !3058
2023-05-15 18:58:04 -04:00
Li-Ta Lo
d05025ce85 simplify comment 2023-05-15 13:05:06 -06:00
Kenneth Moreland
3c1afe53dc Fix new instances of ArrayHandleRuntimeVec in UnknownArrayHandle
`UnknownArrayHandle` is supposed to treat `ArrayHandleRuntimeVec` the
same as `ArrayHandleBasic`. However, the `NewInstance` methods were
failing because they need custom handling of the vec size.
2023-05-12 13:11:23 -06:00
Kenneth Moreland
44650c2e48 Fix unused variable in contour test 2023-05-12 12:00:17 -06:00
Li-Ta Lo
066e6a6969 I think this is the proper way doing PIMPL 2023-05-10 20:05:34 -06:00
Li-Ta Lo
6e75be33ec unique_ptr know if itself is valid 2023-05-10 17:31:50 -06:00
Li-Ta Lo
50a9efc2f5 use rvalue ref for parameter 2023-05-10 17:28:30 -06:00
Li-Ta Lo
61c002072f cleanup C++ usage, use unique_ptr for PIMPL 2023-05-10 10:17:14 -06:00
Louis Gombert
1538fc02fb Implement Flying Edges for all structured CellSets
In addition to  using uniform coordinates, the ContourFlyingEdges filter can now process any type of coordinate system, making the  filter use Flying Edges in more cases
2023-05-10 15:20:53 +02:00
Louis Gombert
a36415ff2b Merge topic 'contour-split'
dcdda3065 Split flying edges and marching cells into separate filters

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <morelandkd@ornl.gov>
Merge-request: !3050
2023-05-10 03:34:20 -04:00
Li-Ta Lo
0c9573e8d3 use mutable instead of const_cast, remove virtual 2023-05-08 09:29:27 -06:00
Li-Ta Lo
86ba9ff31a Merge topic 'unify_uniform_locators'
527940871 revert renaming this to self
58bbc0965 disable AxisAnnontation in unit tests
5787852a8 use Invoker instead of Dispatcher
eab63f68a revert change to CMakeList.txt
3045deb66 rename Adopter -> Adapter
9cdc16c9a fixed warning about float
2d3580636 add baseline image for volume renderer
8c324f824 Vec3f for param
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <morelandkd@ornl.gov>
Merge-request: !3048
2023-05-04 11:18:04 -04:00
Louis Gombert
dcdda3065a Split flying edges and marching cells into separate filters
In order to compile the contour filter more efficiently, we split the contour filter into two separate translation units, corresponding to the new filters ContourFlyingEdges and ContourMarchingCells. The API for Contour filter is left totally unchanged, and tries to use flying edges if the dataset is structured and uniform.
All three contour filters inherit from the `AbstractContour` class, providing utility methods used in the implementations.
2023-05-04 15:20:20 +02:00
Li-Ta Lo
5279408711 revert renaming this to self 2023-05-03 12:35:53 -06:00
Li-Ta Lo
58bbc0965f disable AxisAnnontation in unit tests 2023-05-03 07:14:41 -06:00
Li-Ta Lo
5787852a8e use Invoker instead of Dispatcher 2023-05-01 14:41:16 -06:00
Dave Pugmire
b437634295 Kick the dashboards..... 2023-05-01 14:41:32 -04:00
Dave Pugmire
1ce2922d15 Remove warning. Add BoundsMap methods.
Fix compiler warnings......

Kick the dashboards..........

Kick the dashboards.....

use lambda instead of functor, remove unused code

ArrayHandle::StorageType should be public

StorageType is public in vtkm::cont::ArrayHandle, but some subclasses  
re-declare it as private. Having it public provides a convenient way to  
get the storage type of an ArrayHandle, otherwise it is quite verbose.

Addresses: #314

Tetrahedralize and Triangulate filters check if input is already triangulated

Previously, tetrahedralize/triangulate would blindly convert all the cells to tetrahedra/triangles, even when they were already. Now, the dataset is directly returned if the CellSet is a CellSetSingleType of tetras/triangles, and no further processing is done in the worklets for CellSetExplicit when all shapes are tetras or triangles.

ci,crusher: changed fs to orion

ci,osx,macos: fix value of GIT_CLONE_PATH
2023-05-01 13:05:11 -04:00
Li-Ta Lo
eab63f68ad revert change to CMakeList.txt 2023-04-28 13:51:18 -06:00
Li-Ta Lo
3045deb665 rename Adopter -> Adapter 2023-04-28 13:21:26 -06:00
Li-Ta Lo
9cdc16c9ab fixed warning about float 2023-04-28 08:24:15 -06:00
Li-Ta Lo
8c324f8244 Vec3f for param 2023-04-27 10:18:15 -06:00
Li-Ta Lo
f799826faa use Vec3f for parametric coordinate 2023-04-27 10:10:45 -06:00
Li-Ta Lo
6fa506d60d clean up 2023-04-27 08:29:42 -06:00
Li-Ta Lo
b7b3d51b1d use CRTP to factor out common code 2023-04-26 12:33:05 -06:00
Li-Ta Lo
b1804f591c calculate invSpacing 2023-04-26 11:41:55 -06:00
Li-Ta Lo
4f91cfded4 making the two sampler look closer 2023-04-26 09:02:43 -06:00
Li-Ta Lo
5ccf5dd5bc first cut at delegate RectilinearLocator 2023-04-25 16:42:21 -06:00
Li-Ta Lo
8dcd78b1ba delegate to vtk::cont::CellLocatorUniformGrid 2023-04-25 08:47:57 -06:00
Li-Ta Lo
0fd47317b2 Merge topic 'volume_render_cleanup'
86e6c5c3e use lambda instead of functor, remove unused code

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <morelandkd@ornl.gov>
Acked-by: Manish Mathai <mmathai@uoregon.edu>
Merge-request: !3043
2023-04-21 10:39:30 -04:00
Li-Ta Lo
86e6c5c3e0 use lambda instead of functor, remove unused code 2023-04-20 13:34:58 -06:00
Kenneth Moreland
0182eb9d9d Test variant arguments to worklets
Add a regression test for passing a variant as an argument to a worklet.
Variants are tricky objects, and the compiler might make some strange
assumptions during optimization.

One case that popped up in particular was when a variant contained two
objects with the same `sizeof` but the first object had padding. When the
variant contained the second object, the value under the padded part of
the first object was not set.
2023-04-19 11:30:47 -06:00
Kenneth Moreland
de28a43510 Add an entry to VariantUnion to help compiler copy structs
I've been seeing errors in a nightly build that compiles for CUDA Pascal
using GCC5. The issue is that one of the `ArrayHandleMultiplexer` tests
is failing to copy an implicit array correctly. I think the problem is
that in this test the first and second type of the `Variant` are the same
size, but the first type has some padding in the middle whereas the
second type does not. When using this second type, the values in the
same position of the padding of the first type don't seem to be
initialized properly in the kernel invocation.

My nonexhaustive experiment shows that things work OK as long as the
first type is large enough and has no fillers. Enforce this by adding an
internal entry to the union that is completely full.
2023-04-19 11:14:48 -06:00
Sean Miller
1ac12b784b Adding thrust option for ReduceByKey for Kokkos+HIP/CUDA. 2023-04-17 10:50:57 -05:00
Dave Pugmire
c8702f132b Punch the dashboard in the neck. 2023-04-14 22:29:07 -04:00
Dave Pugmire
d257108236 cleanup and better check for valid seeds. 2023-04-14 14:19:50 -04:00
Dave Pugmire
fe35202de8 Merge branch 'master' of https://gitlab.kitware.com/vtk/vtk-m into sl_block_duplication 2023-04-14 12:54:00 -04:00
Louis Gombert
627b757733 Merge topic 'continuous-scatterplot'
4ba15a993 Add new ContinuousScatterPlot filter

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !3028
2023-04-14 12:01:15 -04:00