Function that complements read_caim()
read_caim_raw(
path = NULL,
z = NULL,
a = NULL,
zenith_colrow = NULL,
radius = 700,
rmax = 100,
k = 1,
p = 1,
only_blue = FALSE,
offset_value = NULL
)
An object from class SpatRaster. Single-layer raster if
only_blue
is equal to TRUE
. Otherwise, a raster with as many layers as
there are distinct colors in the Color Filter Array. Layer names are taken
from the color description metadata.
Character vector of length one.Path to a raw file, including file extension.
SpatRaster built with zenith_image()
.
SpatRaster built with azimuth_image()
.
Numeric vector of length two. Raster coordinates of the
zenith. See calc_zenith_colrow()
.
Numeric integer of length one. Radius of the reprojected hemispherical image (i.e., the output).
Numeric vector of length one. Maximum radius where to search for
knn. Increase this value if pixels with value 0
or
FALSE
appears where other values are expected.
Numeric vector of length one. Number of k-nearest neighbors.
Numeric vector of length one. Power for inverse-distance weighting.
Logical vector of length one. If TRUE
, only values from
the blue or cyan wavelength will be processed.
numeric vector. This values will replace the
black_level_per_channel
metadata obtained with rawpy
.
This function facilitates the integration of the rawpy
Python package into
the R environment via the reticulate
package. This integration allows
rcaiman
to access and pre-process raw data.
Here is a step-by-step guide to assist users in setting up the environment for efficient processing:
To ensure that R can access a Python installation, run the following test:
reticulate::py_eval("1+1")
If R can access Python successfully, you will see 2
in the console. If not,
you will receive instructions on how to install Python.
After passing the Python accessibility test, create a virtual environment using the following command:
reticulate::virtualenv_create()
rawpy
:
Install the rawpy package within the virtual environment:
reticulate::py_install("rawpy")
If you are an RStudio user who works with projects, you will need a .Renviron file in the root of each project. To create a .Renviron file, follow these steps:
Create a "New Blank File" named ".Renviron" (without an extension) in the project's root directory.
Run bellow code:
path <- file.path(reticulate::virtualenv_root(),
reticulate::virtualenv_list(), "Scripts", "python.exe")
paste("RETICULATE_PYTHON =", path)
Copy/paste the line from the console (the string between the quotes) into
the .Renviron file. This is an example RETICULATE_PYTHON = ~/.virtualenvs/r-reticulate/Scripts/python.exe
Do not forget to save the changes
By following these steps, users can easily set up their environment to access raw data efficiently, but it is not the only way of doing it.
Other Tool Functions:
colorfulness()
,
correct_vignetting()
,
defuzzify()
,
extract_dn()
,
extract_feature()
,
extract_rl()
,
extract_sky_points_simple()
,
extract_sky_points()
,
extract_sun_coord()
,
find_sky_pixels_nonnull()
,
find_sky_pixels()
,
masking()
,
optim_normalize()
,
percentage_of_clipped_highlights()
,
read_bin()
,
read_caim()
,
write_bin()
,
write_caim()