raytraverse¶
raytraverse [OPTIONS] COMMAND1 [ARGS]... [COMMAND2 [ARGS]...]...
the raytraverse executable is a command line interface to the raytraverse python package for running and evaluating climate based daylight models. sub commands of raytraverse can be chained but should be invoked in the order given.
the easiest way to manage options is to use a configuration file, to make a template:
raytraverse --template > run.cfg
after adjusting the settings, than each command can be invoked in turn and any dependencies will be loaded with the correct options, a complete run and evaluation can then be called by:
raytraverse -c run.cfg skyrun sunrun
as all required precursor commands will be invoked automatically as needed.
Options
VALUE OPTIONS:
-
-config
,
-c
<PATH>
¶ path of config file to load
-
-n
<INTEGER>
¶ sets the environment variable RAYTRAVERSE_PROC_CAP set to 0 to clear (parallel processes will use cpu_limit)
-
-out
<DIRECTORY>
¶
FLAGS (DEFAULT FALSE):
-
--template
,
--no-template
¶
write default options to std out as config
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
Commands
-
scene
define scene files for renderer and output…
-
area
define sampling area
-
suns
define solar sampling space
-
skydata
define sky conditions for evaluation
-
skyengine
initialize engine for skyrun
-
sunengine
initialize engine for sunrun
-
skyrun
run scene under sky for a set of points…
-
directskyrun
-
sunrun
run scene for a set of suns (defined by…
-
images
render images
-
evaluate
evaluate metrics
-
pull
scene¶
raytraverse scene [OPTIONS]
define scene files for renderer and output directory
Effects¶
creates outdir and outdir/scene.oct
Options
VALUE OPTIONS:
-
-out
<DIRECTORY>
¶
-
-scene
<TEXT>
¶ space separated list of radiance scene files (no sky) or precompiled octree
FLAGS (DEFAULT TRUE):
-
--log
,
--no-log
¶
log progress to stderr
- Default
True
-
--reload
,
--no-reload
¶
if a scene already exists at OUT reload it, note that if this is False and overwrite is False, the program will abort
- Default
True
FLAGS (DEFAULT FALSE):
-
--overwrite
,
--no-overwrite
¶
Warning! if set to True all files inOUT will be deleted
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
area¶
raytraverse area [OPTIONS]
define sampling area
Effects¶
None
Options
VALUE OPTIONS:
-
-jitterrate
<FLOAT>
¶ fraction of each axis to jitter over
- Default
0.5
-
-name
<TEXT>
¶ name for zone/point group (impacts file naming)
- Default
plan
-
-printlevel
<INTEGER>
¶ print a set of sun positions at sampling level (overrides printdata)
-
-ptres
<FLOAT>
¶ initial sampling resolution for points
- Default
1.0
-
-rotation
<FLOAT>
¶ positive Z rotation for point grid alignment
- Default
0.0
-
-static_points
<TEXT>
¶ points to simulate, this can be a .npy file, a whitespace seperated text file or entered as a string with commas between components of a point and spaces between points. points should either all be 3 componnent (x,y,z) or 6 component (x,y,z,dx,dy,dz) but the dx,dy,dz is ignored
-
-zheight
<FLOAT>
¶ replaces z in points or zone
-
-zone
<TEXT>
¶ zone boundary to dynamically sample. can either be a radiance scene file defining a plane to sample or an array of points (same input options as -static_points). Pointsare used to define a convex hull with an offset of 1/2*ptres in which to sample. Note that if static_pointsand zone are both give, static_points is silently ignored
FLAGS (DEFAULT FALSE):
-
--printdata
,
--no-printdata
¶
if True, print areamapper positions (either boundary or static points)
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
suns¶
raytraverse suns [OPTIONS]
define solar sampling space
Effects¶
None
Options
VALUE OPTIONS:
-
-jitterrate
<FLOAT>
¶ fraction of each axis to jitter over
- Default
0.5
-
-loc
<TEXT>
¶ can be a number of formats:
a string of 3 space seperated values (lat lon mer) where lat is +west and mer is tz*15 (matching gendaylit).
a string of comma seperated sun positions with multiple items seperated by spaces: “0,-.7,.7 .7,0,.7” following the shape requirements of 3.
a file loadable with np.loadtxt) of shape (N, 2), (N,3), (N,4), or (N,5):
2 elements: alt, azm (angles in degrees)
3 elements: dx,dy,dz of sun positions
4 elements: alt, azm, dirnorm, diffhoriz (angles in degrees)
5 elements: dx, dy, dz, dirnorm, diffhoriz.
path to an epw or wea formatted file: solar positions are generated and used as candidates unless –epwloc is True.
None (default) all possible sun positions are considered
in the case of a location, sun positions are considered valid when in the solar transit for that location. for candidate options (2., 3., 4.), sun positions are drawn from this set (with one randomly chosen from all candidates within adaptive grid.
-
-name
<TEXT>
¶ name for solar sourcee group (impacts file naming)
- Default
suns
-
-printlevel
<INTEGER>
¶ print a set of sun positions at sampling level (overrides printdata)
-
-skyro
<FLOAT>
¶ counterclockwise sky-rotation in degrees (equivalent to clockwise project north rotation)
- Default
0.0
-
-sunres
<FLOAT>
¶ initial sampling resolution for suns
- Default
20.0
FLAGS (DEFAULT FALSE):
-
--epwloc
,
--no-epwloc
¶
if True, use location from epw/wea argument to -loc as a transit mask (like -loc option 1.) instead of as a list of candidate sun positions.
- Default
False
-
--printdata
,
--no-printdata
¶
if True, print skymapper sun positions (either boundary or candidates in xyz coordinates)
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
skydata¶
raytraverse skydata [OPTIONS]
define sky conditions for evaluation
Effects¶
Invokes scene
write outdir/name.npz (SkyData initialization object)
Options
VALUE OPTIONS:
-
-ground_fac
<FLOAT>
¶ ground reflectance
- Default
0.2
-
-loc
<FLOATS>
¶ location data given as ‘lat lon mer’ with + west of prime meridian overrides location data in wea
-
-minalt
<FLOAT>
¶ minimum solar altitude for daylight masking
- Default
2.0
-
-mindiff
<FLOAT>
¶ minumum diffuse horizontal irradiance for daylight masking
- Default
5.0
-
-mindir
<FLOAT>
¶ minumum direct normal irradiance for daylight masking
- Default
0.0
-
-name
<TEXT>
¶ output file name for skydata
- Default
skydata
-
-skyres
<FLOAT>
¶ approximate square patch size in degrees (must match argument given to skyengine)
- Default
12.0
-
-skyro
<FLOAT>
¶ angle in degrees counter-clockwise to rotate sky (to correct model north, equivalent to clockwise rotation of scene)
- Default
0.0
-
-wea
<TEXT>
¶ path to epw, wea, .npy file or np.array, or .npz file,if loc not set attempts to extract location data (if needed).
FLAGS (DEFAULT TRUE):
-
--reload
,
--no-reload
¶
reload saved skydata if it exists in scene directory
- Default
True
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
skyengine¶
raytraverse skyengine [OPTIONS]
initialize engine for skyrun
Effects¶
Invokes scene
creates outdir/scene_sky.oct
Options
VALUE OPTIONS:
-
-accuracy
<FLOAT>
¶ a generic accuracy parameter that sets the threshold variance to sample. A value of 1 will have a sample count at the final sampling level equal to the number of directions with a contribution variance greater than .25
- Default
1.0
-
-dcompargs
<TEXT>
¶ additional arguments for running direct component. when using, set -ab in sunengine.rayargs to this ab minus one.
- Default
-ab 1
-
-fdres
<INTEGER>
¶ the final directional sampling resolution, yielding a grid of potential samples at 2^fdres x 2^fdres per hemisphere
- Default
9
-
-idres
<INTEGER>
¶ the initial directional sampling resolution. each side of the sampling square (representing a hemisphere) will be subdivided 2^idres, yielding 2^(2*idres) samples and a resolution of 2^(2*idres)/(2pi) samples/steradian. this value should be smaller than 1/2 the size of the smallest view to an aperture that should be captured with 100% certainty
- Default
5
-
-rayargs
<TEXT>
¶ additional arguments to pass to the rendering engine
-
-skyres
<FLOAT>
¶ approximate resolution for skypatch subdivision (in degrees). Patches will have (rounded) size skyres x skyres. So if skyres=10, each patch will be 100 sq. degrees (0.03046174197 steradians) and there will be 18 * 18 = 324 sky patches. Must match argument givein to skydata
- Default
12.0
-
-vlt
<FLOAT>
¶ primary transmitting vlt, used to scale the accuracy parameter to the expected scene variance. Optional, but helpful with, for example, electrochromic glazing or shades
- Default
0.64
FLAGS (DEFAULT TRUE):
-
--default-args
,
--no-default-args
¶
use raytraverse defaults before -rayargs, if False, uses radiance defaults
- Default
True
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
sunengine¶
raytraverse sunengine [OPTIONS]
initialize engine for sunrun
Effects¶
Invokes scene
Options
VALUE OPTIONS:
-
-accuracy
<FLOAT>
¶ a generic accuracy parameter that sets the threshold variance to sample. A value of 1 will have a sample count at the final sampling level equal to the number of directions with a contribution variance greater than .25
- Default
1.0
-
-fdres
<INTEGER>
¶ the final directional sampling resolution, yielding a grid of potential samples at 2^fdres x 2^fdres per hemisphere
- Default
10
-
-idres
<INTEGER>
¶ the initial directional sampling resolution. each side of the sampling square (representing a hemisphere) will be subdivided 2^idres, yielding 2^(2*idres) samples and a resolution of 2^(2*idres)/(2pi) samples/steradian. this value should be smaller than 1/2 the size of the smallest view to an aperture that should be captured with 100% certainty
- Default
5
-
-maxspec
<FLOAT>
¶ the maximum value in the specular guide considered as a specular reflection source. Above this value it is assumed that these are direct view rays to the source so are not sampled. in the case of low vlt glazing, set -vlt. In mixed (high-low) vlt scenes the specular guide will either over sample (including direct views when maxspec is large) or under sample (miss specular reflections when maxspec is small) depending on this setting.
- Default
0.2
-
-rayargs
<TEXT>
¶ additional arguments to pass to the rendering engine
-
-slimit
<FLOAT>
¶ the minimum value in the specular guide considered as a potential specular reflection source, in the case of low vlt glazing, make sure to set -vlt.
- Default
0.01
-
-speclevel
<INTEGER>
¶ at this sampling level, pdf is made from brightness of sky sampling rather than progressive variance to look for fine scale specular highlights, this should be atleast 1 level from the end and the resolution of this level should be smaller than the size of the source
- Default
9
-
-vlt
<FLOAT>
¶ primary transmitting vlt, used to scale the accuracy parameter to the expected scene variance. Optional, but helpful with, for example, electrochromic glazing or shades
- Default
0.64
FLAGS (DEFAULT TRUE):
-
--default-args
,
--no-default-args
¶
use raytraverse defaults before -rayargs, if False, uses radiance defaults
- Default
True
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
skyrun¶
raytraverse skyrun [OPTIONS]
run scene under sky for a set of points (defined by area)
Effects¶
Invokes scene
Invokes area (no effects)
Invokes skyengine
- creates outdir/area.name/sky_points.tsv
contents: 5cols x N rows: [sample_level idx x y z]
- creates outdir/area.name/sky/######.rytpt
each file is a LightPointKD initialization object
Options
VALUE OPTIONS:
-
-accuracy
<FLOAT>
¶ parameter to set threshold at sampling level relative to final level threshold (smaller number will increase sampling)
- Default
1.0
-
-edgemode
<CHOICE>
¶ if ‘constant’ value is set to -self.t1, so edge is always seen as detail. Internal edges (resulting from PlanMapper borders) will behave like ‘nearest’ for all options except ‘constant’
- Default
constant
- Options
constant | reflect | nearest | mirror | wrap
-
-nlev
<INTEGER>
¶ number of levels to sample (final resolution will be ptres/2^(nlev-1))
- Default
3
FLAGS (DEFAULT TRUE):
-
--jitter
,
--no-jitter
¶
jitter samples on plane within adaptive sampling grid
- Default
True
FLAGS (DEFAULT FALSE):
-
--overwrite
,
--no-overwrite
¶
If True, reruns sampler when invoked, otherwise will first attempt to load results
- Default
False
-
--plotp
,
--no-plotp
¶
plot pdfs and sample vecs for each level
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
directskyrun¶
raytraverse directskyrun [OPTIONS]
Options
FLAGS (DEFAULT FALSE):
-
--overwrite
,
--no-overwrite
¶
If True, reruns sampler when invoked, otherwise will first attempt to load results
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
sunrun¶
raytraverse sunrun [OPTIONS]
run scene for a set of suns (defined by suns) for a set of points (defined by area)
Effects¶
Invokes scene
Invokes area (no effects)
Invokes sunengine (no effects)
invokes skyrun (if guided=True)
- creates outdir/area.name/sun_####_points.tsv
contents: 5cols x N rows: [sample_level idx x y z]
- creates outdir/area.name/sky/sun_####/######.rytpt
each file is a LightPointKD initialization object
Options
VALUE OPTIONS:
-
-accuracy
<FLOAT>
¶ parameter to set threshold at sampling level relative to final level threshold (smaller number will increase sampling)
- Default
1.0
-
-edgemode
<CHOICE>
¶ if ‘constant’ value is set to -self.t1, so edge is always seen as detail. Internal edges (resulting from PlanMapper borders) will behave like ‘nearest’ for all options except ‘constant’
- Default
constant
- Options
constant | reflect | nearest | mirror | wrap
-
-nlev
<INTEGER>
¶ number of levels to sample (final resolution will be ptres/2^(nlev-1))
- Default
3
-
-srcaccuracy
<FLOAT>
¶ parameter to set threshold at sampling level relative to final level threshold (smaller number will increase sampling)
- Default
1.0
-
-srcnlev
<INTEGER>
¶ number of levels to sample (final resolution will be sunres/2^(nlev-1))
- Default
3
FLAGS (DEFAULT TRUE):
-
--guided
,
--no-guided
¶
If True, uses skysampling results to guide sun sampling this is necessary if the model has any specular reflections, will raise an error if skyrun has not been called yet.
- Default
True
-
--jitter
,
--no-jitter
¶
jitter samples on plane within adaptive sampling grid
- Default
True
-
--recover
,
--no-recover
¶
If True, recovers existing sampling
- Default
True
-
--srcjitter
,
--no-srcjitter
¶
jitter solar source within adaptive sampling grid for candidate SkyMappers, only affects weighting of selecting candidates in the same grid true positions are still used
- Default
True
FLAGS (DEFAULT FALSE):
-
--overwrite
,
--no-overwrite
¶
If True, reruns sampler when invoked, otherwise will first attempt to load results
- Default
False
-
--plotp
,
--no-plotp
¶
plot pdfs and sample vecs for each level
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
images¶
raytraverse images [OPTIONS]
render images
Prequisites¶
skyrun and sunrun must be manually invoked prior to this
Effects¶
Invokes scene
Invokes skydata
invokes area (no effects)
invokes suns (no effects)
writes: output images according to –namebyindex
Options
VALUE OPTIONS:
-
-basename
<TEXT>
¶ prefix of namebyindex.
- Default
results
-
-interpolate
<CHOICE>
¶ - Options
linear | fast | high | | None | False
-
-res
<INTEGER>
¶ image resolution
- Default
800
-
-resuntol
<FLOAT>
¶ tolerance for resampling sun views
- Default
5.0
-
-sdirs
<TEXT>
¶ sensor directions, this can be a .npy file, a whitespace seperated text file or entered as a string with commas between components of a point and spaces between points. vectors should all be 3 componnent (dx,dy,dz). used with3-component -sensors argument, all points are run for allviews, creating len(sensors)*len(sdirs) results. thisis the preferred option for multiple view directions, asthe calculations are grouped more efficiently
-
-sensors
<TEXT>
¶ sensor points, this can be a .npy file, a whitespace seperated text file or entered as a string with commas between components of a point and spaces between points. points should either all be 3 componnent (x,y,z) or 6 component (x,y,z,dx,dy,dz). If 3 component, -sdirs is required, if 6-component, -sdirs is ignored
-
-simtype
<CHOICE>
¶ simulation process/integration type
- Default
3comp
- Options
1comp | 2comp | 3comp | directview | directpatch | sunonly | sunpatch | skyonly
-
-skymask
<INTS>
¶ mask to reduce output from full SkyData, enter as index rows in wea/epw file using space seperated list or python range notation:
370 371 372 (10AM-12PM on jan. 16th)
12:8760:24 (everyday at Noon)
-
-viewangle
<FLOAT>
¶ - Default
180.0
FLAGS (DEFAULT FALSE):
-
--blursun
,
--no-blursun
¶
for simulating point spread function for direct sun view
- Default
False
-
--directview
,
--no-directview
¶
if True, ignore sky data and use daylight factors directly
- Default
False
-
--namebyindex
,
--no-namebyindex
¶
if False (default), names images by: <prefix>_sky-<row>_pt-<x>_<y>_<z>_vd-<dx>_<dy>_<dz>.hdr if True, names images by: <prefix>_sky-<row>_pt-<pidx>_vd-<vidx>.hdr, where pidx, vidx refer to the order of points, and vm.
- Default
False
-
--resampleview
,
--no-resampleview
¶
resample direct sun view directions
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
evaluate¶
raytraverse evaluate [OPTIONS]
evaluate metrics
Prequisites¶
skyrun and sunrun must be manually invoked prior to this
Effects¶
Invokes scene
Invokes skydata
invokes area (no effects)
invokes suns (no effects)
writes: <basename>.npz light result file (use “raytraverse pull” to extract data views)
Options
VALUE OPTIONS:
-
-basename
<TEXT>
¶ LightResult object is written to basename.npz.
- Default
results
-
-metrics
<TEXTS>
¶ metrics to compute, choices: [“illum”, “avglum”, “gcr”, “ugp”, “dgp”, “tasklum”, “backlum”, “dgp_t1”, “log_gc”, “dgp_t2”, “ugr”, “threshold”, “pwsl2”, “view_area”, “backlum_true”, “srcillum”, “srcarea”, “maxlum”]
- Default
illum dgp ugp
-
-resuntol
<FLOAT>
¶ tolerance for resampling sun views
- Default
5.0
-
-sdirs
<TEXT>
¶ sensor directions, this can be a .npy file, a whitespace seperated text file or entered as a string with commas between components of a point and spaces between points. vectors should all be 3 componnent (dx,dy,dz). used with3-component -sensors argument, all points are run for allviews, creating len(sensors)*len(sdirs) results. thisis the preferred option for multiple view directions, asthe calculations are grouped more efficiently
-
-sensors
<TEXT>
¶ sensor points, this can be a .npy file, a whitespace seperated text file or entered as a string with commas between components of a point and spaces between points. points should either all be 3 componnent (x,y,z) or 6 component (x,y,z,dx,dy,dz). If 3 component, -sdirs is required, if 6-component, -sdirs is ignored
-
-simtype
<CHOICE>
¶ simulation process/integration type
- Default
3comp
- Options
1comp | 2comp | 3comp | directview | directpatch | sunonly | sunpatch | skyonly
-
-skymask
<INTS>
¶ mask to reduce output from full SkyData, enter as index rows in wea/epw file using space seperated list or python range notation:
370 371 372 (10AM-12PM on jan. 16th)
12:8760:24 (everyday at Noon)
-
-threshold
<FLOAT>
¶ same as the evalglare -b option. if factor is larger than 100, it is used as constant threshold in cd/m2, else this factor is multiplied by the average task luminance. task position is center of image with a 30 degree field of view
- Default
2000.0
-
-viewangle
<FLOAT>
¶ - Default
180.0
FLAGS (DEFAULT TRUE):
-
--npz
,
--no-npz
¶
write LightResult object to .npz, use ‘raytraverse pull’or LightResult(‘basename.npz’) to access results
- Default
True
FLAGS (DEFAULT FALSE):
-
--blursun
,
--no-blursun
¶
for simulating point spread function for direct sun view
- Default
False
-
--lowlight
,
--no-lowlight
¶
use lowlight correction for dgp
- Default
False
-
--resampleview
,
--no-resampleview
¶
resample direct sun view directions
- Default
False
-
--serr
,
--no-serr
¶
include columns of sampling info/errors columns are: sun_pt_err, sun_pt_bin, sky_pt_err, sky_pt_bin, sun_err, sun_bin. ‘err’ is distance from queried vector to actual. ‘bin’ is the unraveled idx of source vector at a 500^2 resolution of the mapper.
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
pull¶
raytraverse pull [OPTIONS]
Options
VALUE OPTIONS:
-
-col
<TEXTS>
¶ axis to preserve and order for flattening, if not all axes are specified default order is (sky, point, view, metric) the first value is the column preserved, the second (with -ofiles) is the file to write, and the rest determine the order for ravelling into rows.
- Default
metric
-
-imgfilter
<INTS>
¶ image indices to return (ignored for lightfield result)
-
-imgzone
<TEXT>
¶ for making images from ZonalLightResult, path to areato sample over.
-
-lr
<FILE>
¶ .npz LightResult, overrides lightresult from chained commands (evaluate/imgmetric). required if not chained with evaluate or imgmetric.
-
-metricfilter
<TEXTS>
¶ metrics to return (non-existant are ignored)
-
-ofiles
<TEXT>
¶ if given output serialized files along first axis (given by order) with naming [ofiles]_XXXX.txt
-
-ptfilter
<INTS>
¶ point indices to return (ignored for imgmetric result)
-
-skyfill
<FILE>
¶ path to skydata file. assumes rows are timesteps. skyfilter should be None and other beside col should reduce to 1 or ofiles is given and sky is not first in order and all but first reduces to 1. LightResult should be a full evaluation (not masked)
-
-skyfilter
<INTS>
¶ sky indices to return (ignored for imgmetric result)
-
-spd
<INTEGER>
¶ steps per day. for use with –gridhdr col != sky matches data underlying -skyfill
- Default
24
-
-viewfilter
<INTS>
¶ view direction indices to return (ignored for imgmetric result)
FLAGS (DEFAULT TRUE):
-
--header
,
--no-header
¶
print col labels
- Default
True
-
--rowlabel
,
--no-rowlabel
¶
label row
- Default
True
FLAGS (DEFAULT FALSE):
-
--gridhdr
,
--no-gridhdr
¶
use with ‘ofiles’, order ‘X point/sky Y’ and make sure Y only has one value (with appropriate filter)
- Default
False
-
--info
,
--no-info
¶
skip execution and return shape and axis info about LightResult
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
raytu¶
raytu [OPTIONS] COMMAND1 [ARGS]... [COMMAND2 [ARGS]...]...
the raytu executable is a command line interface to utility commands as part of the raytraverse python package.
the easiest way to manage options is to use a configuration file, to make a template:
raytu --template > run.cfg
after adjusting the settings, than each command can be invoked in turn and any dependencies will be loaded with the correct options, for example:
raytraverse -c run.cfg imgmetric pull
will calculate metrics on a set of images and then print to the stdout.
Options
VALUE OPTIONS:
-
-config
,
-c
<PATH>
¶ path of config file to load
-
-n
<INTEGER>
¶ sets the environment variable RAYTRAVERSE_PROC_CAP set to 0 to clear (parallel processes will use cpu_limit)
FLAGS (DEFAULT FALSE):
-
--template
,
--no-template
¶
write default options to std out as config
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
Commands
-
transform
coordinate transformations
-
imgmetric
calculate metrics for hdr images, similar…
-
img2lf
read and compress angular fisheye images…
-
pull
-
padsky
pad filtered result data according to sky…
transform¶
raytu transform [OPTIONS]
coordinate transformations
Options
VALUE OPTIONS:
-
-cols
<INTS>
¶ coordinate columns (if none uses first N as required)
-
-d
<TEXT>
¶ a .npy file, a whitespace seperated text file (can be - for stdin) or entered as a string with commas between components of a point and spaces between rows.
-
-op
<CHOICE>
¶ transformation: ‘xyz2xy’: cartesian direction vector to equiangular. ‘xyz2aa’: cartesian direction vector to alt/azimuth. ‘xyz2tp’: cartesian to spherical (normalized). ‘xyz2uv’: cartesian to shirley-chiu square. ‘uv2xyz’: shirley-chiu square to certesian.
- Default
xyz2xy
- Options
xyz2xy | xyz2aa | xyz2tp | xyz2uv | uv2xyz
-
-outf
<TEXT>
¶ if none, return to stdout, else save as text file
-
-reshape
<INTS>
¶ reshape before transform (before flip)
FLAGS (DEFAULT FALSE):
-
--flip
,
--no-flip
¶
transpose matrix before transform (after reshape)
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
imgmetric¶
raytu imgmetric [OPTIONS]
calculate metrics for hdr images, similar to evalglare but without glare source grouping, equivalent to -r 0 in evalglare. This ensures that all glare source positions are weighted by the metrics to which they are applied. Additional peak normalization reduces the deviation between images processed in different ways, for example pfilt with -r, rpict drawsource(), or an undersampled vwrays | rtrace run where the pixels give a coarse estimate of the actual sun area.
Options
VALUE OPTIONS:
-
-basename
<TEXT>
¶ LightResult object is written to basename.npz.
- Default
img_metrics
-
-imgs
<FILES>
¶ hdr image files, must be angular fisheye projection,if no view in header, assumes 180 degree
-
-metrics
<TEXTS>
¶ metrics to compute, choices: [“illum”, “avglum”, “gcr”, “ugp”, “dgp”, “tasklum”, “backlum”, “dgp_t1”, “log_gc”, “dgp_t2”, “ugr”, “threshold”, “pwsl2”, “view_area”, “backlum_true”, “srcillum”, “srcarea”, “maxlum”]
- Default
illum dgp ugp
-
-peaka
<FLOAT>
¶ expected peak area over which peak energy is distributed
- Default
6.7967e-05
-
-peakr
<FLOAT>
¶ for peaks that do not meet expected area (such as partial suns, to determines the ratio of what counts as part of the source (max/peakr)
- Default
4.0
-
-peakt
<FLOAT>
¶ include down to this threshold in possible peak, note thatonce expected peak energy is satisfied remaining pixels aremaintained, so it is safe-ish to keep this value low
- Default
100000.0
-
-scale
<FLOAT>
¶ scale factor applied to pixel values to convert to cd/m^2
- Default
179.0
-
-threshold
<FLOAT>
¶ same as the evalglare -b option. if factor is larger than 100, it is used as constant threshold in cd/m2, else this factor is multiplied by the average task luminance. task position is center of image with a 30 degree field of view
- Default
2000.0
FLAGS (DEFAULT TRUE):
-
--npz
,
--no-npz
¶
write LightResult object to .npz, use ‘raytraverse pull’or LightResult(‘basename.npz’) to access results
- Default
True
-
--parallel
,
--no-parallel
¶
use available cores
- Default
True
-
--peakn
,
--no-peakn
¶
corrrect aliasing and/or filtering artifacts for direct sun by assigning up to expected energy to peakarea
- Default
True
FLAGS (DEFAULT FALSE):
-
--blursun
,
--no-blursun
¶
applies human PSF to peak glare source (only if peekn=True
- Default
False
-
--lowlight
,
--no-lowlight
¶
use lowlight correction for dgp
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
img2lf¶
raytu img2lf [OPTIONS]
read and compress angular fisheye images into lightpoints/lightplane
Options
VALUE OPTIONS:
-
-imga
<FILES>
¶ hdr image files, primary view direction, must be angular fisheye projection, view header required
-
-imgb
<FILES>
¶ hdr image files, opposite view direction, must be angular fisheye projection, assumed to be same as imga with -vd reversed
-
-out
<DIRECTORY>
¶ output directory
- Default
imglf
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
pull¶
raytu pull [OPTIONS]
Options
VALUE OPTIONS:
-
-col
<TEXTS>
¶ axis to preserve and order for flattening, if not all axes are specified default order is (sky, point, view, metric) the first value is the column preserved, the second (with -ofiles) is the file to write, and the rest determine the order for ravelling into rows.
- Default
metric
-
-imgfilter
<INTS>
¶ image indices to return (ignored for lightfield result)
-
-imgzone
<TEXT>
¶ for making images from ZonalLightResult, path to areato sample over.
-
-lr
<FILE>
¶ .npz LightResult, overrides lightresult from chained commands (evaluate/imgmetric). required if not chained with evaluate or imgmetric.
-
-metricfilter
<TEXTS>
¶ metrics to return (non-existant are ignored)
-
-ofiles
<TEXT>
¶ if given output serialized files along first axis (given by order) with naming [ofiles]_XXXX.txt
-
-ptfilter
<INTS>
¶ point indices to return (ignored for imgmetric result)
-
-skyfill
<FILE>
¶ path to skydata file. assumes rows are timesteps. skyfilter should be None and other beside col should reduce to 1 or ofiles is given and sky is not first in order and all but first reduces to 1. LightResult should be a full evaluation (not masked)
-
-skyfilter
<INTS>
¶ sky indices to return (ignored for imgmetric result)
-
-spd
<INTEGER>
¶ steps per day. for use with –gridhdr col != sky matches data underlying -skyfill
- Default
24
-
-viewfilter
<INTS>
¶ view direction indices to return (ignored for imgmetric result)
FLAGS (DEFAULT TRUE):
-
--header
,
--no-header
¶
print col labels
- Default
True
-
--rowlabel
,
--no-rowlabel
¶
label row
- Default
True
FLAGS (DEFAULT FALSE):
-
--gridhdr
,
--no-gridhdr
¶
use with ‘ofiles’, order ‘X point/sky Y’ and make sure Y only has one value (with appropriate filter)
- Default
False
-
--info
,
--no-info
¶
skip execution and return shape and axis info about LightResult
- Default
False
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False
padsky¶
raytu padsky [OPTIONS]
pad filtered result data according to sky filtering
Options
VALUE OPTIONS:
-
-cols
<INTS>
¶ cols of data to return (default all)
-
-data
<TEXT>
¶ data to pad
-
-loc
<FLOATS>
¶ location data given as ‘lat lon mer’ with + west of prime meridian overrides location data in wea
-
-minalt
<FLOAT>
¶ minimum solar altitude for daylight masking
- Default
2.0
-
-mindiff
<FLOAT>
¶ minumum diffuse horizontal irradiance for daylight masking
- Default
5.0
-
-mindir
<FLOAT>
¶ minumum direct normal irradiance for daylight masking
- Default
0.0
-
-wea
<TEXT>
¶ path to epw, wea, .npy file or np.array, or .npz file,if loc not set attempts to extract location data (if needed).
HELP:
-
-opts
,
--opts
¶
check parsed options
- Default
False
-
--debug
¶
show traceback on exceptions
- Default
False
-
--version
¶
Show the version and exit.
- Default
False