Exports
Exports aim to provide a consistent generation of images of your results. For example if you record the trace your algorithm walks on the Sphere, you can easily export this trace to a rendered image using asymptote_export_S2_signals
and render the result with Asymptote. Despite these, you can always record values during your iterations, and export these, for example to csv
.
Asymptote
The following functions provide exports both in graphics and/or raw data using Asymptote.
Manopt.asymptote_export_S2_data
— Methodasymptote_export_S2_data(filename)
Export given data
as an array of points on the 2-sphere, which might be one-, two- or three-dimensional data with points on the Sphere$\mathbb S^2$.
Input
filename
a file to store the Asymptote code in.
Optional arguments for the data
data
a point representing the 1D,2D, or 3D array of pointselevation_color_scheme
AColorScheme
for elevationscale_axes
: ((1/3,1/3,1/3)
) move spheres closer to each other by a factor per direction
Optional arguments for asymptote
arrow_head_size
: (1.8
) size of the arrowheads of the vectors (in mm)camera_position
position of the camera scene (default: atop the center of the data in the xy-plane)target
position the camera points at (default: center of xy-plane within data).
Manopt.asymptote_export_S2_signals
— Methodasymptote_export_S2_signals(filename; points, curves, tangent_vectors, colors, options...)
Export given points
, curves
, and tangent_vectors
on the sphere $\mathbb S^2$ to Asymptote.
Input
filename
a file to store the Asymptote code in.
Optional arguments for the data
colors
dictionary of color arrays (indexed by symbols:points
,:curves
and:tvector
) where each entry has to provide as least as many colors as the length of the corresponding sets.curves
anArray
ofArrays
of points on the sphere, where each inner array is interpreted as a curve and is accompanied by an entry withincolors
points
anArray
ofArrays
of points on the sphere where each inner array is interpreted as a set of points and is accompanied by an entry withincolors
tangent_vectors
anArray
ofArrays
of tuples, where the first is a points, the second a tangent vector and each set of vectors is accompanied by an entry from withincolors
Optional arguments for asymptote
arrow_head_size
: (6.0
) size of the arrowheads of the tangent vectorsarrow_head_sizes
overrides the previous value to specify a value pertVector
` set.camera_position
: ((1., 1., 0.)
) position of the camera in the Asymptote sceneline_width
: (1.0
) size of the lines used to draw the curves.line_widths
overrides the previous value to specify a value per curve andtVector
` set.dot_size
: (1.0
) size of the dots used to draw the points.dot_sizes
overrides the previous value to specify a value per point set.size
: (nothing
) a tuple for the image size, otherwise a relative size4cm
is used.sphere_color
: (RGBA{Float64}(0.85, 0.85, 0.85, 0.6)
) color of the sphere the data is drawn onsphere_line_color
: (RGBA{Float64}(0.75, 0.75, 0.75, 0.6)
) color of the lines on the spheresphere_line_width
: (0.5
) line width of the lines on the spheretarget
: ((0.,0.,0.)
) position the camera points at
Manopt.asymptote_export_SPD
— Methodasymptote_export_SPD(filename)
export given data
as a point on a Power(SymmetricPOsitiveDefinnite(3))}
manifold of one-, two- or three-dimensional data with points on the manifold of symmetric positive definite matrices.
Input
filename
a file to store the Asymptote code in.
Optional arguments for the data
data
a point representing the 1D, 2D, or 3D array of SPD matricescolor_scheme
aColorScheme
for Geometric Anisotropy Indexscale_axes
: ((1/3,1/3,1/3)
) move symmetric positive definite matrices closer to each other by a factor per direction compared to the distance estimated by the maximal eigenvalue of all involved SPD points
Optional arguments for asymptote
camera_position
position of the camera scene (default: atop the center of the data in the xy-plane)target
position the camera points at (default: center of xy-plane within data).
Both values camera_position
and target
are scaled by scaledAxes*EW
, where EW
is the maximal eigenvalue in the data
.
Manopt.render_asymptote
— Methodrender_asymptote(filename; render=4, format="png", ...)
render an exported asymptote file specified in the filename
, which can also be given as a relative or full path
Input
filename
filename of the exportedasy
and rendered image
Keyword arguments
the default values are given in brackets
render
: (4
) render level of asymptote passed to its-render
option. This can be removed from the command by setting it tonothing
.format
: ("png"
) final rendered format passed to the-f
optionexport_file
: (the filename with format as ending) specify the export filename