Commit Graph

68 Commits

Author SHA1 Message Date
Kenneth Moreland
796ec9638e Document data that comes from VisIt tutorial
Some of the data sets that are included from VTK-m are derived from the
VisIt Tutorial Data (https://www.visitusers.org/index.php?title=Tutorial_Data).
These are covered by the VisIt license, as communicated by Eric Brugger.

Although the license for these data is compatible with VTK-m's license,
we should still attribute the source of the data and make clear the
copyrights. The data are moved into the third_party directory, and
readmes are added to document everything.

The noise.vtk and noise.bov files have been renamed example.vtk and
example_temp.bov to match the name of the file in the VisIt tutorial
data archive. The ucd3d.vtk file, which is similar to the curv3d.silo
data but altered, has been removed. It was not used for any tests. It
was referenced in a couple of example programs, but the reference is
easily changed.
2023-03-14 12:25:21 -06:00
Vicente Adolfo Bolea Sanchez
049d0cca8c cmake: namespace vtkm export targets 2022-12-09 18:46:56 -05:00
Kenneth Moreland
ad1e7b5bdb Add module mechanism
This mechanism sets up CMake variables that allow a user to select which
modules/libraries to create. Dependencies will be tracked down to ensure
that all of a module's dependencies are also enabled.

The modules are also arranged into groups.
Groups allow you to set the enable flag for a group of modules at once.
Thus, if you have several modules that are likely to be used together,
you can create a group for them.

This can be handy in converting user-friendly CMake options (such as
`VTKm_ENABLE_RENDERING`) to the modules that enable that by pointing to
the appropriate group.
2022-10-26 12:51:05 -06:00
Li-Ta Lo
9e2148dbf0 remove device compiler 2022-08-01 16:28:18 -06:00
Li-Ta Lo
93a85d01db update example/clipping 2022-01-11 08:08:42 -07:00
Li-Ta Lo
3c700259a1 migrate Contour, ClipWithField and Slice 2022-01-10 20:39:43 -07:00
Kenneth Moreland
264a8a4b6c Remove dependence of examples on testing files
The testing files (even the headers) are not available if
`VTKm_ENABLE_TESTING` is off.

Mostly, the testing was used to generate example data sets. Instead,
change the examples to load data files.
2021-09-08 08:54:15 -06:00
Kenneth Moreland
8657a9b3c8 Update VTKDataSetWriter to compile into vtkm_io 2020-05-19 14:32:48 -06:00
NAThompson
697369fc14 Remove deprecation warnings throughout the project. 2020-04-30 08:12:04 -04:00
Sujin Philip
c102ea556c Update cmake minimum required version to 3.12 2020-04-13 12:42:28 -05:00
Robert Maynard
1bfcce19dd VTK-m builds with separate function sections to allow smaller binaries
Consumers of VTK-m when enabling of dropping of unused functions
will see VTK-m functions dropped. Previously this didn't happen
as VTK-m didn't build object files with the correct flags for this.

By allowing the linker to remove unused symbols we see a significant
saving the file size of VTK-m tests, examples, and benchmarks.
An OpenMP build of the tests and benchmarks goes from 168MB to
141MB which is roughly a 16% filesize reduction.

Initially I had presumed that these changes would increase link times.
But in measurements the total wall time for compilation of VTK-m has
stayed about the same ( seeing a decrease of 1.5% ). Presumably the
increased computation is offset by the reduction in file writing.
2019-09-11 13:34:25 -04:00
Robert Maynard
267f963d32 Opt into all CMake 3.15 policies 2019-08-20 15:38:27 -04:00
Kenneth Moreland
fb3c9e8186 Modernize clipping example
That example was written way before the filter classes ever existed. Now
by using the clip filter, everything becomes very simple.
2019-08-07 09:13:56 -06:00
Kenneth Moreland
0be50c119d Update VTK-m code to use new Vec aliases
Should make the code easier to read.
2019-07-31 12:55:40 -06:00
Robert Maynard
28484fc6aa Update examples and benchmarks to use new VTK-m CMake helper function 2019-07-09 13:32:23 -04:00
nadavi
fbcea82e78 conslidate the license statement 2019-04-17 10:57:13 -06:00
Robert Maynard
ff30684c8e Removes the default device macros from VTK-m
Fixes #116
2019-04-15 08:15:36 -04:00
Robert Maynard
0ce7e82d43 VTK-m now enables all new CMake policies in 3.14
This means that we opt-in to policy changes introduced in 3.14
2019-03-26 11:50:06 -04:00
Haocheng LIU
415252c662 Introduce asynchronous and device independent timer
The timer class now is asynchronous and device independent. it's using an
similiar API as vtkOpenGLRenderTimer with Start(), Stop(), Reset(), Ready(),
and GetElapsedTime() function. For convenience and backward compability, Each
Start() function call will call Reset() internally and each GetElapsedTime()
function call will call Stop() function if it hasn't been called yet for keeping
backward compatibility purpose.

Bascially it can be used in two modes:

* Create a Timer without any device info. vtkm::cont::Timer time;

  * It would enable timers for all enabled devices on the machine. Users can get a
specific elapsed time by passing a device id into the GetElapsedtime function.
If no device is provided, it would pick the maximum of all timer results - the
logic behind this decision is that if cuda is disabled, openmp, serial and tbb
roughly give the same results; if cuda is enabled it's safe to return the
maximum elapsed time since users are more interested in the device execution
time rather than the kernal launch time. The Ready function can be handy here
to query the status of the timer.

* Create a Timer with a device id. vtkm::cont::Timer time((vtkm::cont::DeviceAdapterTagCuda()));

  * It works as the old timer that times for a specific device id.
2019-02-05 12:01:56 -05:00
Kenneth Moreland
887f79c6f4 Make a vtkm_worklet library
This is a library that contains parts of worklets that can be
precompiled into a library.

Currently, this library contains the implementation of ScatterCounting.
2019-01-23 17:09:15 -07:00
Robert Maynard
f1e1a524e9 Require CMake 3.8 to build VTK-m. 2019-01-09 16:01:22 -05:00
Robert Maynard
0a40c620ac Rename ArrayHandleVariant to VariantArrayHandle. 2018-12-27 14:35:56 -05:00
Robert Maynard
b138798604 Update examples to work with ArrayHandleVariant/Virtual 2018-12-27 14:35:56 -05:00
Kenneth Moreland
bddad9b386 Remove TryExecute from filters
Now that the dispatcher does its own TryExecute, filters do not need to
do that. This change requires all worklets called by filters to be able
to execute without knowing the device a priori.
2018-10-16 15:59:53 -06:00
Robert Maynard
9861cdecb1 Use CMake to automatically set policies to NEW.
CMake 3.12 introduces a ...<max> syntax in the version given to
cmake_minimum_required to automatically set policies to NEW up
to that version. Use it to avoid listing policies explicitly.
2018-06-19 16:12:48 -04:00
Haocheng LIU
5c797169ec Use the strong typed enums for vtkm::cont::Field
Since Field association is used either when creating or working
with 'vtkm::cont::Field', it's put in the class itself.
2018-05-22 11:44:51 -04:00
Robert Maynard
8808b41fbd Merge branch 'master' into vtk-m-cmake_refactor 2018-03-29 22:51:26 -04:00
Matt Larsen
cf0b0aaf95 fixing clipping and contour tree examples 2018-03-10 09:08:29 -08:00
Robert Maynard
ec074bb627 Redesign how we specify cxx files should be compiled as cuda.
Due to limitations in the CUDA MSBuild support and how CMake stores the language
of a source file, we had to change VTK-m over to using generated .cu files
to signal when we want CUDA compilation.
2018-01-16 15:42:37 -05:00
Robert Maynard
0660c67fef Merge branch 'master' into vtk-m-cmake_refactor 2018-01-16 15:42:28 -05:00
Sujin Philip
70fcd1d1cc Update CoordinateSystem to use the Virtual Array 2018-01-10 10:19:19 -05:00
Robert Maynard
b10e50860f Update all the examples to the new CMake code. 2018-01-08 14:00:57 -05:00
Robert Maynard
ed8f4111ef Update all the code to work with CMake 3.3
Obviously this does mean that CUDA is not supported with 3.3.
2017-10-27 15:30:14 -04:00
Robert Maynard
3ded554831 Extend the CMake rewrite to include vtkm_rendering 2017-10-27 15:29:58 -04:00
Robert Maynard
56c7362258 A thought on what CMake 3.9 would mean to VTK-m. 2017-10-27 15:29:51 -04:00
Kenneth Moreland
c3a3184d51 Update copyright for Sandia
Sandia National Laboratories recently changed management from the
Sandia Corporation to the National Technology & Engineering Solutions
of Sandia, LLC (NTESS). The copyright statements need to be updated
accordingly.
2017-09-20 15:33:44 -06:00
Robert Maynard
c0b08b5a9f Convert examples over to using 'using' over 'typedef' 2017-08-10 13:46:17 -04:00
David C. Lonie
0564af0a5f Fix Clipping example compilation.
Some functions were refactored and broke this example code.
2017-06-28 12:20:09 -04:00
Robert Maynard
5dd346007b Respect VTK-m convention of parameters all or nothing on a line
clang-format BinPack settings have been disabled to make sure that the
VTK-m style guideline is obeyed.
2017-05-26 13:53:28 -04:00
Kitware Robot
4ade5f5770 clang-format: apply to the entire tree 2017-05-25 07:51:37 -04:00
Kitware Robot
efbde1d54b clang-format: sort include directives 2017-05-18 12:59:33 -04:00
Robert Maynard
e415f55b6f Update the examples to work with the new usage requirements 2017-01-27 10:03:53 -05:00
Robert Maynard
5ec273aade Remove all occurrences of boost::lexical_cast from vtk-m.
Replaced with the new std::stof/stoi functions.
2016-10-20 16:55:15 -04:00
Robert Maynard
4521403fd2 Examples now correctly request the optional CUDA component 2016-09-14 15:29:04 -04:00
Sujin Philip
011605d489 Refactor CMake files
1. Change set_property(...) to target_* commands
2. Remove explcit adding of CMAKE_CXX_FLAGS_WARN_EXTRA as compile option
3. Add /bigobj option to VTKm_COMPILE_OPTIONS under MSVC
2016-09-01 11:14:29 -04:00
Kenneth Moreland
866c617cbf Fix config issues with headers and libraries
There were a couple of places where the configure scripts did not add
either includes to VTKm_INCLUDE_DIRS or libraries to VTKm_LIBRARIES.

The biggest offender was when the examples used find_package to load the
VTK-m configuration it needed. find_package cleared out the includes and
libraries, but it did not clear out the VTKm_<COMPONENT>_FOUND
variables. Normally, these variables would not be set before
find_package is called, but in this case the examples were called after
some partial configuration. I got around this issue by clearing out all
the *_FOUND variables in VTKmConfig.cmake.
2016-08-23 14:07:38 -06:00
Robert Maynard
88ce3f23ae Examples now call find_package(VTKm)
The examples are now written so they can be copied out of the vtk-m
source and still build properly. This will help new users / developers
learn how to build projects that use VTK-m.
2016-08-22 14:03:16 -04:00
Robert Maynard
af05ea0e8d Cleanup clipping so we can use it from a filter. 2016-08-18 12:50:20 -04:00
Robert Maynard
31138293f9 Pass Fields and CoordinateSystems to Dispatcher::Invoke
Now that we can handle scheduling Fields and CoordinateSystems, do
2016-08-05 15:26:17 -04:00
Robert Maynard
aa01784a06 Remove unused result warnings from StreamLineUniformGrid example. 2016-07-15 11:40:52 -04:00