🚀
Fast & Device Agnostic
Effortlessly execute your code on CPU, GPU, and TPU with MLIR and XLA.
Optimize Julia Functions With MLIR and XLA for High-Performance Execution on CPU, GPU, TPU and more.
Its easy to install Reactant.jl. Since Reactant.jl is registered in the Julia General registry, you can simply run the following command in the Julia REPL:
julia> using Pkg
julia> Pkg.add("Reactant")If you want to use the latest unreleased version of Reactant.jl, you can run the following command:
julia> using Pkg
julia> Pkg.add(url="https://github.com/EnzymeAD/Reactant.jl")using Reactant
Reactant.set_default_backend("cpu")using Reactant
# Set backend to use a GPU if available
Reactant.set_default_backend("gpu")
# Set backend to specifically a CUDA GPU
# Reactant.set_default_backend("cuda")using Reactant
Reactant.set_default_backend("gpu")
# Set backend to specifically an AMD GPU
# Reactant.set_default_backend("rocm")using Reactant
Reactant.set_default_backend("tpu")using Reactant
Reactant.set_default_backend("tt")