ViennaCS is a header-only C++ cell set library, which adds the possibility of using volumetric representations on top of existing level-set functionalities for surfaces. Combined with ray tracing techniques, this enables the simulation of particle scattering and ion implantation.
Note
ViennaCS is under heavy development and improved daily. If you do have suggestions or find bugs, please let us know!
Releases are tagged on the main branch and available in the releases section.
-
Linux (g++ / clang)
-
macOS (XCode)
-
Windows (Visual Studio)
- C++17 Compiler with OpenMP support
-
pybind11 (only for building Python libs)
The CMake configuration automatically checks if the dependencies are installed.
If the dependencies are not found on the system, they will be built from source. To use local installations of the dependencies, the VIENNACS_LOOKUP_DIRS
variable can be set to the installation path of the dependencies.
Since this is a header only project, it does not require any installation. However, we recommend the following procedure in order to set up all dependencies correctly:
git clone https://github.com/ViennaTools/ViennaCS.git
cd ViennaCS
cmake -B build && cmake --build build
cmake --install build --prefix "/path/to/your/custom/install/"
This will install the necessary headers and CMake files to the specified path. If --prefix
is not specified, it will be installed to the standard path for your system, usually /usr/local/
.
The Python package can be built and installed using the pip
command:
git clone https://github.com/ViennaTools/ViennaCS.git
cd ViennaCS
pip install .
Some functionalities of the ViennaCS Python module only work in combination with the ViennaLS Python module. It is therefore recommended to additionally install the ViennaLS Python module on your system. Instructions to do so can be found in the ViennaLS Git Repository.
The 2D version of the library can be imported as follows:
import viennacs2d as vcs
In order to switch to three dimensions, only the import needs to be changed:
import viennacs3d as vcs
We recommend using CPM.cmake to consume this library.
-
Installation with CPM
CPMAddPackage("gh:viennatools/[email protected]")
-
With a local installation
In case you have ViennaCS installed in a custom directory, make sure to properly specify the
CMAKE_PREFIX_PATH
.list(APPEND CMAKE_PREFIX_PATH "/your/local/installation") find_package(ViennaCS) target_link_libraries(${PROJECT_NAME} PUBLIC ViennaTools::ViennaCS)
The examples can be built using CMake:
Important: Make sure all dependencies are installed and have been built previously
git clone https://github.com/ViennaTools/ViennaCS.git
cd ViennaCS
cmake -B build -DVIENNACS_BUILD_EXAMPLES=ON
cmake --build build
ViennaCS uses CTest to run its tests. In order to check whether ViennaCS runs without issues on your system, you can run:
git clone https://github.com/ViennaTools/ViennaCS.git
cd ViennaCS
cmake -B build -DVIENNACS_BUILD_TESTS=ON
cmake --build build
ctest -E "Benchmark|Performance" --test-dir build
If you want to contribute to ViennaCS, make sure to follow the LLVM Coding guidelines.
Make sure to format all files before creating a pull request:
cmake -B build
cmake --build build --target format
Current contributors: Tobias Reiter, Felix Strasser
Contact us via: [email protected]
ViennaCS was developed under the aegis of the 'Institute for Microelectronics' at the 'TU Wien'. http://www.iue.tuwien.ac.at/
See file LICENSE in the base directory.