This function helps to predict the target variable observations based on the covariates. The prediction is working in parallel across vegetated pixels.
Usage
parallel_prediction(
base.map.dir,
models,
cov.vecs,
non.na.inds,
outdir,
name,
cores = parallel::detectCores()
)Arguments
- base.map.dir
character: path to the GeoTIFF file within which the extents and CRS will be used to generate the ensemble maps.
- models
list: trained models across ensemble members generated by the `parallel_train` function.
- cov.vecs
numeric: data frame containing covaraites across vegetated pixels generated from the `stack_covariates_2_df` function.
- non.na.inds
numeric: the corresponding index of vegetated pixels generated from the `stack_covariates_2_df` function.
- outdir
character: the output directory where the downscaled maps will be stored.
- name
list: containing the time and variable name to create the final GeoTIFF file name.
- cores
numeric: how many CPus to be used in the calculation, the default is the total CPU number you have.