LOCATION_INFO (C++)#

LocationInfoResponse invertedai::location_info(LocationInfoRequest &location_info_request, Session *session)#

Wrap the REST API “location_info”. Provides static information about a given location.

See also

invertedai::initialize

See also

invertedai::drive

See also

invertedai::blame

Parameters:
  • location_info_request – the location_info request to send to the API

  • session – the shared session connected with the host

Returns:

the location_info response receive from the API


class LocationInfoRequest#

Public Functions

LocationInfoRequest(const std::string &body_str)#

A request sent to receive an LocationInfoResponse from the API.

std::string body_str()#

Serialize all the fields into a string.

const std::string url_query_string() const#

Return a query string containing the (key, value) pairs, which can be concatenated to the url.

std::string location() const#

Get the location string in IAI format.

bool include_map_source() const#

Check whether include the map source.

std::optional<int> rendering_fov() const#

Get the fov for both x and y axis for the rendered birdview in meters.

std::optional<std::pair<double, double>> rendering_center() const#

Get the center coordinates for the rendered birdview.

void set_location(const std::string &location)#

Set the location string in IAI format.

void set_include_map_source(bool include_map_source)#

Set whether include the map source.

void set_rendering_fov(std::optional<int> rendering_fov)#

Set the fov for both x and y axis for the rendered birdview in meters.

void set_rendering_center(const std::optional<std::pair<double, double>> &rendering_center)#

Set the center coordinates for the rendered birdview.

class LocationInfoResponse#

Public Functions

LocationInfoResponse(const std::string &body_str)#
std::string body_str()#

Serialize all the fields into a string.

std::string version() const#

Get map version. Matches the version in the input location string, if one was specified.

int max_agent_number() const#

Get Maximum number of agents recommended in the location. Use more at your own risk.

std::vector<Point2d> bounding_polygon() const#

Get convex polygon denoting the boundary of the supported area within the location.

std::vector<unsigned char> birdview_image() const#

Get the visualization of the location.

std::string osm_map() const#

Underlying map annotation, returned if include_map_source was set.

Point2d map_origin() const#

Get the origin of the map.

std::vector<StaticMapActor> static_actors() const#

Lists traffic lights with their IDs and locations.

void set_version(const std::string &version)#

Set map version. Matches the version in the input location string, if one was specified.

void set_max_agent_number(int max_agent_number)#

Set maximum number of agents recommended in the location.

void set_bounding_polygon(const std::vector<Point2d> &bounding_polygon)#

Set convex polygon denoting the boundary of the supported area within the location.

void set_birdview_image(const std::vector<unsigned char> &birdview_image)#

Setter for birdview_image.

void set_osm_map(const std::string &osm_map)#

Setter for osm_map.

void set_map_origin(const Point2d map_origin)#

Setter for map_origin.

void set_static_actors(const std::vector<StaticMapActor> &static_actors)#

Setter for static_actors.