Installation
This package is a registered package.
Install via
using Pkg; pkg"add SolidStateDetectors"Visualization / Plotting (Optional)
This package provides serveral plot recipes for different outputs for the plotting package Plots.jl.
In order to use these also install the Plots.jl package via
using Pkg; pkg"add Plots"Load the Plots.jl package (and optionally the backend pyplot) via
using PlotsThe backends supported by SolidStateDetectors.jl are gr and pyplot. By default, gr is loaded when importing Plots.
For more information about the plot recipes of this package look up the Plotting section.
This documentation was build with
Plots: v1.26.0 - GR: v0.64.0GPU Support in Field Calculations
The Electric Potential and individual Weighting Potentials can also be calculated on GPUs.
In order to use your GPU, the Julia Packages CUDAKernels or ROCKernels have to be installed and loaded.
In case of an NVIDIA GPU:
using CUDAKernels, SolidStateDetectorsIn case of an AMD GPU:
using ROCKernels, SolidStateDetectorsThen, in any field calculation (calculate_electric_potential!, calculate_weighting_potential!, simulate!(::Simulation)) the keyword device_array_type can be set to choose the device on which the calculations should be performed. The possibilities are:
device_array_type = Array # -> CPU (default)
device_array_type = CuArray # -> NVIDIA GPU
device_array_type = ROCArray # -> AMD GPUThe GPU Array types are available through CUDAKernels and ROCKernels:
using CUDAKernels.CUDA: CuArray
using ROCKernels.AMDGPU: ROCArrayExample (NVIDIA)
using CUDAKernels, SolidStateDetectors
using CUDAKernels.CUDA: CuArray
sim = Simulation(SSD_examples[:CGD])
calculate_electric_potential!(
sim,
device_array_type = CuArray,
refinement_limits = [0.2, 0.1, 0.05],
depletion_handling = true
) The AMD backend was not yet tested due to lack of an AMD GPU (we are working on that).