io.io_controlnetwork
— ISIS Compatible Control Network Creation¶
The io.io_controlnetwork
module supports the creation of control networks in ISIS format.
New in version 0.1.0.
- class plio.io.io_controlnetwork.IsisControlNetwork(data=None, index: Axes | None = None, columns: Axes | None = None, dtype: Dtype | None = None, copy: bool | None = None)[source]¶
- class plio.io.io_controlnetwork.IsisStore(path, mode=None, **kwargs)[source]¶
Class to manage IO of an ISIS control network (version 2). .. attribute:: pointid
The current index to be assigned to newly added points
- type:
int
- create_buffer_header(networkid, targetname, description, username, point_sizes, creation_date, modified_date)[source]¶
Create the Google Protocol Buffer header using the protobuf spec. :param networkid: The user defined identifier of this control network :type networkid: str :param targetname: The name of the target, e.g. Moon :type targetname: str :param description: A description for the network. :type description: str :param username: The name of the user / application that created the control network :type username: str :param point_sizes: of the point sizes for each point message :type point_sizes: list
- Returns:
header_message (str) – The serialized message to write
header_message_size (int) – The size of the serialized header, in bytes
- create_points(df, pointid_prefix, pointid_suffix)[source]¶
Step through a control network (C) and return protocol buffer point objects :param df: with the appropriate attributes: point_id, point_type, serial,
measure_type, x, y required. The entries in the list must support grouping by the point_id attribute.
- Returns:
point_messages (list) – of serialized points buffers
point_sizes (list) – of integer point sizes
- create_pvl_header(version, headerstartbyte, networkid, targetname, description, username, buffer_header_size, points_bytes, creation_date, modified_date)[source]¶
Create the PVL header object :param version: The current ISIS version to write, defaults to 2 :type version: int :param headerstartbyte: The seek offset that the protocol buffer header starts at :type headerstartbyte: int :param networkid: The name of the network :type networkid: str :param targetname: The name of the target, e.g. Moon :type targetname: str :param description: A description for the network. :type description: str :param username: The name of the user / application that created the control network :type username: str :param buffer_header_size: Total size of the header in bytes :type buffer_header_size: int :param points_bytes: The total number of bytes all points require :type points_bytes: int
- Returns:
An ISIS compliant PVL header object
- Return type:
object
- class plio.io.io_controlnetwork.MeasureMessageType(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]¶
An enum to mirror the ISIS3 MeasureLogData enum.
- plio.io.io_controlnetwork.write_filelist(lst, path='fromlist.lis')[source]¶
Writes a filelist to a file so it can be used in ISIS3. :param lst: A list containing full paths to the images used, as strings. :type lst: list :param path: The name of the file to write out. Default: fromlist.lis :type path: str