API reference
Capse.CℓEmulator
— TypeCℓEmulator(TrainedEmulator::AbstractTrainedEmulators, ℓgrid::Array,
InMinMax::Matrix, OutMinMax::Matrix)
This is the fundamental struct used to obtain the $C_\ell$'s from an emulator. It contains:
TrainedEmulator::AbstractTrainedEmulators
, the trained emulatorℓgrid::AbstractVector
, the $\ell$-grid the emulator has been trained on.InMinMax::AbstractMatrix
, theMatrix
used for the MinMax normalization of the input featuresOutMinMax::AbstractMatrix
, theMatrix
used for the MinMax normalization of the output featuresPostprocessing::Function
, theFunction
used for the postprocessing of the NN output
Capse.get_Cℓ
— Functionget_Cℓ(input_params, Cℓemu::AbstractCℓEmulators)
Computes and returns the $C_\ell$'s on the $\ell$-grid the emulator has been trained on given input array input_params
.
Capse.get_ℓgrid
— Functionget_ℓgrid(CℓEmulator::AbstractCℓEmulators)
Returns the $\ell$-grid the emulator has been trained on.
AbstractCosmologicalEmulators.get_emulator_description
— Functionget_emulator_description(Cℓemu::AbstractCℓEmulators)
Print on screen the emulator description.
Capse.load_emulator
— Functionload_emulator(path::String, emu_backend::AbstractTrainedEmulators)
Load the emulator with the files in the folder path
, using the backend defined by emu_backend
. The following keyword arguments are used to specify the name of the files used to load the emulator:
ℓ_file
, defaultl.npy
weights_file
, defaultweights.npy
inminmax_file
, defaultinminmax.npy
outminmax_file
, defaultoutminmax.npy
nn_setup_file
, defaultnn_setup.json
postprocessing_file
, defaultpostprocessing.jl
If the corresponding file in the folder you are trying to load have different names, change the default values accordingly.