> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kinetica.com/llms.txt
> Use this file to discover all available pages before exploring further.

# /visualize/isochrone

```
URL: http://<db.host>:<db.port>/visualize/isochrone
```

Generate an image containing isolines for travel results using an existing
graph. Isolines represent curves of equal cost, with cost typically referring
to the time or distance assigned as the weights of the underlying graph. See
[Graphs and Solvers](https://docs.kinetica.com/content/graph_solver/network_graph_solver.md) for more
information on graphs.

## Input Parameter Description

**graph\_name** `string`

Name of the graph on which the isochrone is to be computed.

**source\_node** `string`

Starting vertex on the underlying graph from/to which the isochrones are created.

**max\_solution\_radius** `double`

Extent of the search radius around input parameter *source\_node*. Set to '-1.0' for unrestricted search radius.

The default value is -1.0.

**weights\_on\_edges** `array of strings`

Additional weights to apply to the edges of an existing graph. Weights must be specified using [identifiers](https://docs.kinetica.com/content/graph_solver/network_graph_solver.md#identifiers); identifiers are grouped as [combinations](https://docs.kinetica.com/content/graph_solver/network_graph_solver.md#id-combos). Identifiers can be used with existing column names, e.g., 'table.column AS WEIGHTS\_EDGE\_ID', or expressions, e.g., 'ST\_LENGTH(wkt) AS WEIGHTS\_VALUESPECIFIED'. Any provided weights will be added (in the case of 'WEIGHTS\_VALUESPECIFIED') to or multiplied with (in the case of 'WEIGHTS\_FACTORSPECIFIED') the existing weight(s).

The default value is an empty array ( \[] ).

**restrictions** `array of strings`

Additional restrictions to apply to the nodes/edges of an existing graph. Restrictions must be specified using [identifiers](https://docs.kinetica.com/content/graph_solver/network_graph_solver.md#identifiers); identifiers are grouped as [combinations](https://docs.kinetica.com/content/graph_solver/network_graph_solver.md#id-combos). Identifiers can be used with existing column names, e.g., 'table.column AS RESTRICTIONS\_EDGE\_ID', or expressions, e.g., 'column/2 AS RESTRICTIONS\_VALUECOMPARED'. If *remove\_previous\_restrictions* is set to *true*, any provided restrictions will replace the existing restrictions. If *remove\_previous\_restrictions* is set to *false*, any provided restrictions will be added (in the case of 'RESTRICTIONS\_VALUECOMPARED') to or replaced (in the case of 'RESTRICTIONS\_ONOFFCOMPARED').

The default value is an empty array ( \[] ).

**num\_levels** `int`

Number of equally-separated isochrones to compute.

The default value is 1.

**generate\_image** `boolean`

If set to *true*, generates a PNG image of the isochrones in the response.

The default value is `true`.

The supported values are:

* true
* false

**levels\_table** `string`

Name of the table to output the isochrones to, in \[schema\_name.]table\_name format, using standard [name resolution rules](https://docs.kinetica.com/content/concepts/tables.md#table-name-resolution) and meeting [table naming criteria](https://docs.kinetica.com/content/concepts/tables.md#table-naming-criteria). The table will contain levels and their corresponding WKT geometry. If no value is provided, the table is not generated.

The default value is ''.

**style\_options** `map of string to strings`

Various style related options of the isochrone image.

**style\_options**

**line\_size**

The width of the contour lines in pixels.

The default value is `3`. The minimum allowed value is `0`. The maximum allowed value is `20`.

**color**

Color of generated isolines. All color values must be in the format RRGGBB or AARRGGBB (to specify the alpha value). If alpha is specified and flooded contours are enabled, it will be used for as the transparency of the latter.

The default value is `FF696969`.

**bg\_color**

When input parameter *generate\_image* is set to *true*, background color of the generated image. All color values must be in the format RRGGBB or AARRGGBB (to specify the alpha value).

The default value is `00000000`.

**text\_color**

When *add\_labels* is set to *true*, color for the labels. All color values must be in the format RRGGBB or AARRGGBB (to specify the alpha value).

The default value is `FF000000`.

**colormap**

Colormap for contours or fill-in regions when applicable. All color values must be in the format RRGGBB or AARRGGBB (to specify the alpha value).

The default value is `jet`.

The supported values are:

* jet
* accent
* afmhot
* autumn
* binary
* blues
* bone
* brbg
* brg
* bugn
* bupu
* bwr
* cmrmap
* cool
* coolwarm
* copper
* cubehelix
* dark2
* flag
* gist\_earth
* gist\_gray
* gist\_heat
* gist\_ncar
* gist\_rainbow
* gist\_stern
* gist\_yarg
* gnbu
* gnuplot2
* gnuplot
* gray
* greens
* greys
* hot
* hsv
* inferno
* magma
* nipy\_spectral
* ocean
* oranges
* orrd
* paired
* pastel1
* pastel2
* pink
* piyg
* plasma
* prgn
* prism
* pubu
* pubugn
* puor
* purd
* purples
* rainbow
* rdbu
* rdgy
* rdpu
* rdylbu
* rdylgn
* reds
* seismic
* set1
* set2
* set3
* spectral
* spring
* summer
* terrain
* viridis
* winter
* wistia
* ylgn
* ylgnbu
* ylorbr
* ylorrd

**solve\_options** `map of string to strings`

Solver specific parameters.

The default value is an empty map ( \{} ).

**solve\_options**

**remove\_previous\_restrictions**

Ignore the restrictions applied to the graph during the creation stage and only use the restrictions specified in this request if set to *true*.

The default value is `false`.

The supported values are:

* true
* false

**restriction\_threshold\_value**

Value-based restriction comparison. Any node or edge with a 'RESTRICTIONS\_VALUECOMPARED' value greater than the *restriction\_threshold\_value* will not be included in the solution.

**uniform\_weights**

When specified, assigns the given value to all the edges in the graph. Note that weights provided in input parameter *weights\_on\_edges* will override this value.

**contour\_options** `map of string to strings`

Contour specific parameters.

The default value is an empty map ( \{} ).

**contour\_options**

**projection**

Spatial Reference System (i.e. EPSG Code).

The default value is `PLATE_CARREE`.

The supported values are:

* 3857
* 102100
* 900913
* EPSG:4326
* PLATE\_CARREE
* EPSG:900913
* EPSG:102100
* EPSG:3857
* WEB\_MERCATOR

**width**

When input parameter *generate\_image* is set to *true*, width of the generated image.

The default value is `512`.

**height**

When input parameter *generate\_image* is set to *true*, height of the generated image. If the default value is used, the *height* is set to the value resulting from multiplying the aspect ratio by the *width*.

The default value is `-1`.

**search\_radius**

When interpolating the graph solution to generate the isochrone, neighborhood of influence of sample data (in percent of the image/grid).

The default value is `20`.

**grid\_size**

When interpolating the graph solution to generate the isochrone, number of subdivisions along the x axis when building the grid (the y is computed using the aspect ratio of the output image).

The default value is `100`.

**color\_isolines**

Color each isoline according to the colormap; otherwise, use the foreground color.

The default value is `true`.

The supported values are:

* true
* false

**add\_labels**

If set to *true*, add labels to the isolines.

The default value is `false`.

The supported values are:

* true
* false

**labels\_font\_size**

When *add\_labels* is set to *true*, size of the font (in pixels) to use for labels.

The default value is `12`.

**labels\_font\_family**

When *add\_labels* is set to *true*, font name to be used when adding labels.

The default value is `arial`.

**labels\_search\_window**

When *add\_labels* is set to *true*, a search window is used to rate the local quality of each isoline. Smooth, continuous, long stretches with relatively flat angles are favored. The provided value is multiplied by the *labels\_font\_size* to calculate the final window size.

The default value is `4`.

**labels\_intralevel\_separation**

When *add\_labels* is set to *true*, this value determines the  distance (in multiples of the *labels\_font\_size*) to use when separating labels of different values.

The default value is `4`.

**labels\_interlevel\_separation**

When *add\_labels* is set to *true*, this value determines the distance (in percent of the total window size) to use when separating labels of the same value.

The default value is `20`.

**labels\_max\_angle**

When *add\_labels* is set to *true*, maximum angle (in degrees) from the vertical to use when adding labels.

The default value is `60`.

**options** `map of string to strings`

Additional parameters.

The default value is an empty map ( \{} ).

**options**

**solve\_table**

Name of the table to host intermediate solve results, in \[schema\_name.]table\_name format, using standard [name resolution rules](https://docs.kinetica.com/content/concepts/tables.md#table-name-resolution) and meeting [table naming criteria](https://docs.kinetica.com/content/concepts/tables.md#table-naming-criteria). This table will contain the position and cost for each vertex in the graph. If the default value is used, a temporary table is created and deleted once the solution is calculated.

The default value is ''.

**is\_replicated**

If set to *true*, replicate the *solve\_table*.

The default value is `true`.

The supported values are:

* true
* false

**data\_min\_x**

Lower bound for the x values. If not provided, it will be computed from the bounds of the input data.

**data\_max\_x**

Upper bound for the x values. If not provided, it will be computed from the bounds of the input data.

**data\_min\_y**

Lower bound for the y values. If not provided, it will be computed from the bounds of the input data.

**data\_max\_y**

Upper bound for the y values. If not provided, it will be computed from the bounds of the input data.

**concavity\_level**

Factor to qualify the concavity of the isochrone curves. The lower the value, the more convex (with '0' being completely convex and '1' being the most concave).

The default value is `0.5`. The minimum allowed value is `0`. The maximum allowed value is `1`.

**use\_priority\_queue\_solvers**

Sets the solver methods explicitly if true.

The default value is `false`.

* **true**: Uses the solvers scheduled for 'shortest\_path' and 'inverse\_shortest\_path' based on *solve\_direction*.
* **false**: Uses the solvers 'priority\_queue' and 'inverse\_priority\_queue' based on *solve\_direction*.

**solve\_direction**

Specify whether we are going to the source node, or starting from it.

The default value is `from_source`.

* **from\_source**: Shortest path to get to the source (inverse Dijkstra).
* **to\_source**: Shortest path to source (Dijkstra).

## Output Parameter Description

The Kinetica server embeds the endpoint response inside a standard response structure which contains status information and the actual response to the query.  Here is a description of the various fields of the wrapper:

**status** `String`

'OK' or 'ERROR'

**message** `String`

Empty if success or an error message

**data\_type** `String`

'visualize\_isochrone\_response' or 'none' in case of an error

**data** `String`

Empty string

**data\_str** `JSON or String`

This embedded JSON represents the result of the /visualize/isochrone endpoint:

**data\_str**

**width** `int`

Width of the image as provided in *width*.

**height** `int`

Height of the image as provided in *height*.

**bg\_color** `long`

Background color of the image as provided in *bg\_color*.

**image\_data** `bytes`

Generated contour image data.

**info** `map of string to strings`

Additional information.

**solve\_info** `map of string to strings`

Additional information.

**contour\_info** `map of string to strings`

Additional information.

Empty string in case of an error.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.