IlpAnalysisApi.xid.xml 15.2 KB
<?xml version="1.0" encoding="UTF-8" ?>

<specification xmlns="https://xid.location.studio/schema/V1.0.0/XtensibleInterfaceDefinition.xsd"
               xmlns:xid="https://xid.location.studio/schema/V1.0.0/XtensibleInterfaceDefinition.xsd"
               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:schemaLocation="https://xid.location.studio/schema/V1.0.0/XtensibleInterfaceDefinition.xsd https://xid.location.studio/schema/V1.0.0/XtensibleInterfaceDefinition.xsd"
               identity="IlpAnalysisApi.xid.xml">
  <title>ILP Analysis API Specifications</title>
  <comment>
    This file defines the ILP analysis API specification used by the analysis service and internal components.
  </comment>

  <!-- Include all known definitions -->
  <import ref="https://xid.location.studio/GeoSpatial/V1.0/SpatialDefs.xid.xml" local="SpatialDefs.xid.xml" />
  <import ref="https://xid.location.studio/GeoSpatial/V1.0/Contact.xid.xml" local="Contact.xid.xml" />
  <import ref="https://xid.location.studio/SLAM/V1.0/SurveyApi.xid.xml" local="SurveyApi.xid.xml" />
  <import ref="https://xid.location.studio/HPE/V1.2/HpeCore.xid.xml" local="HpeCore.xid.xml" />


  <namespace name="ILP.Analysis">
    <using namespace="Tensor"/>
    
    <!-- 
    *************************************
    * Filter Structure Definition
    *************************************
    -->
    <struct name="Filter">
      <comment>Specifies filter parameters controlling selection of records in the Data Set.</comment>
      <elem name="obsTypes" multiplicity ="0..*" type="uint8" >
        <comment>Optional set of observation types to use in execution.  If not defined, all observation types will be passed to ILP.  This filter
        limits the data presented to the ILP.</comment>
      </elem>
      <elem name="earliestDate" type="datetime" multiplicity="0..1">
        <comment>Optional earliest date to select records.  If not defined, earliest date is not considered.</comment>
      </elem>
      <elem name="latestDate" type="datetime" multiplicity="0..1">
        <comment>Optional latest date to select records.  If not defined, latest date is not considered.</comment>
      </elem>
      <elem name="bounds" multiplicity ="0..1" type="GeoSpatial.BoundingBox" >
        <comment>Optional bounding box, which the records are contained.</comment>
      </elem>
      <elem name="devids" multiplicity ="0..*" type="string" >
        <comment>Optional set of device idenifers to select for execution.</comment>
      </elem>
    </struct>


    <!-- 
    *************************************
    * DataSet Structure Definition. 
    *************************************
    -->
    <struct name="DataSet" type="GeoSpatial.Object" rttkey="GeoSpatial.ObjectType.IlpTestDataSet">
      <comment>DataSet comprises one or more surveys to use as analysis test records.</comment>
      <elem name="uuidData" multiplicity ="0..*" type="UUID" >
        <comment>Zero or more UUIDs identifying the survey test data to include in this data set.</comment>
      </elem>
      <elem name="testdata" multiplicity ="0..*" type="SLAM.SurveyData" >
        <comment>Zero or more SLAM surveys comprising the test data to execute.</comment>
      </elem>
      <elem name="returnFilteredData" multiplicity ="1" type="bool" default ="false">
        <comment>Optional boolean, determines if filtered data should be returned to caller for future testing and analysis.</comment>
      </elem>
      <elem name="uriServices" multiplicity = "1..*" type="Tensor.uri">
          <comment>One or more services to use to process the specified data sets.   Analysis can comprise multiple services 
          processing the datasets and producing reports that provide a comparative performance. Check the API documentation for
          querying a list of available service URIs (e.g. ILPS, etc.).
          </comment>
      </elem>      
    </struct>

    <!-- 
    *************************************
    * Specification Structure Definition. 
    *************************************
    -->
    <struct name="Specification" type="GeoSpatial.Object" rttkey="GeoSpatial.ObjectType.IlpTestSpecification">
      <comment>Specification for an ILP Test comprising one or more data sets.</comment>
      
      <elem name="createDate" type="datetime" multiplicity="1">
        <comment>Date and time the test specification was created.</comment>
      </elem>
      
      <elem name="modifiedDate" type="datetime" multiplicity="1">
        <comment>Date and time the test specification was modified.</comment>
      </elem>
      
      <elem name="extendedResults" multiplicity=[1] type="bool" default="false">
          <comment>
              Specifies whether to provide extended test result records with state and velocity fields.  By
              default, this is false. This is typically used with GNSS data analysis,  indoor analysis will rarely use 
              these fields.
          </comment> 
      </elem>

      <elem name="contact" multiplicity ="0..1" type="GeoSpatial.ContactInfo" >
        <comment>Optional contact information.</comment>
      </elem>

      <elem name="datasets" multiplicity="0..*" type="DataSet">
        <comment>Dataset specifications to process.</comment>
      </elem>
      

    </struct>

    <!-- 
    *************************************
    * ResultRecord Definition. 
    *************************************
    -->
    <struct name="ResultRecord" >
      <comment>Result Record contains detailed results of position calculation and information relative to truth. Optional fields will be included when 
      the Specification.extendedResults is true.</comment>

      <elem name="index" type="uint32"  multiplicity="1" />
      <elem name="epoch" type="datetime" multiplicity="1" />
      <elem name="resultcode" type="ResultCode" multiplicity="1" />
      <elem name="status" type="HPE.ProcessingStatus" multiplicity="1" />
      <elem name="source" type="string" multiplicity="1" />
      <elem name="llaTruth" type="GeoSpatial.PositionECEF" multiplicity="1" />
      <elem name="llaEst" type="GeoSpatial.PositionECEF" multiplicity="1" />
      <elem name="enuUncert" type="GeoSpatial.XYZVector" multiplicity="1" />
      <elem name="enuErr" type="GeoSpatial.XYZVector" multiplicity="1" />
      <elem name="floor" type="float32" multiplicity="1" />
      <elem name="floorTruth" type="float32" multiplicity="1" />
      <elem name="floorUncert" type="float32" multiplicity="1" />
      <elem name="floorErr" type="float32" multiplicity="1" />
      <elem name="floorLabel" type="string" multiplicity="1" />
      <elem name="veracity" type="float32" multiplicity="1" />
      <elem name="enuVelEst" type="GeoSpatial.XYZVector" multiplicity="0..1" />
      <elem name="enuVelErr" type="GeoSpatial.XYZVector" multiplicity="0..1" />
      <elem name="stateTruth" type="HPE.StateVector" multiplicity="0..1" />
      <elem name="stateEst" type="HPE.StateVector" multiplicity="0..1" />
      <elem name="stateUncert" type="HPE.StateVector" multiplicity="0..1" />
      <elem name="stateErr" type="HPE.StateVector" multiplicity="0..1" />
      <elem name="miscdata" type="json" multiplicity="0..1" />
    </struct>

    <!-- 
    *************************************
    * Statistics Definition. 
    *************************************
    -->
    <struct name="Statistics" >
      <comment>Calculated statistics for the associated the results.</comment>

      <elem name="count" type="uint32" multiplicity="1" />
      <elem name="outliers" type="uint32" multiplicity="1" />
      <elem name="cep50" type="float32"  multiplicity="1" />
      <elem name="cep68" type="float32" multiplicity="1" />
      <elem name="cep95" type="float32" multiplicity="1" />
      <elem name="cepmax" type="float32" multiplicity="1" />
      <elem name="rmsuncert" type="float32" multiplicity="1" />
      <elem name="rmserr" type="float32" multiplicity="1" />
      <elem name="rmsEnuErr" type="GeoSpatial.XYZVector" multiplicity="1" />
      <elem name="rmsEnuUncert" type="GeoSpatial.XYZVector" multiplicity="1" />
      <elem name="meanFloor" type="float32" multiplicity="1" />
      <elem name="rmsFloorUncert" type="float32" multiplicity="1" />
      <elem name="rmsFloorErr" type="float32" multiplicity="1" />
      <elem name="meanEnuVel" type="GeoSpatial.XYZVector" multiplicity="0..1" />
      <elem name="rmsEnuVelUncert" type="GeoSpatial.XYZVector" multiplicity="0..1" />
      <elem name="rmsEnuVelErr" type="GeoSpatial.XYZVector" multiplicity="0..1" />
      <elem name="meanState" type="HPE.StateVector" multiplicity="0..1" />
      <elem name="rmsStateErr" type="HPE.StateVector" multiplicity="0..1" />

    </struct>

    <!-- 
    *************************************
    * ResultSet Structure Definition. 
    *************************************
    -->
    <struct name="ServiceResults" type="GeoSpatial.Object" rttkey="GeoSpatial.ObjectType.IlpTestResultSet">
      <comment>Specification for an ILP analysis test data result set.</comment>

      <elem name="confidence" type="float32" multiplicity="1" >
        <comment>Confidence for the result records. Typically this will be one standard deviation (0.6872) but will report the confidence specified by the input.</comment>
      </elem>

      <elem name="uriService" multiplicity = "1" type="Tensor.uri">
          <comment>URI of the service used  process the specified datasets.   This is one of the services specified in DataSet/uriServices field.
          Analysis can comprise multiple services processing the datasets and producing reports that provide a comparative performance. Check the API documentation for
          querying a list of available service URIs (e.g. ILPS, etc.).
          </comment>
      </elem>
      
      <elem name="stats" type="Statistics" multiplicity="1">
        <comment>Statistics for the result set.</comment>
      </elem>

      <elem name="records" type="ResultRecord" multiplicity="0..*">
        <comment>The estimated position result records.</comment>
      </elem>

    </struct>

    <!-- 
    *************************************
    * Results Structure Definition. 
    *************************************
    -->
    <struct name="DataSetResults" type="GeoSpatial.Object" rttkey="GeoSpatial.ObjectType.IlpTestResults">
      <comment>Specification for an ILP analysis test data result set.</comment>

      <elem name="startExecutionDate" type="datetime" multiplicity="1">
        <comment>Date and time the test was executed.</comment>
      </elem>      

      <elem name="durationExecution" type="uint32" multiplicity="1">
        <tag name="unit" value="msec"/>
        <comment>Duration of the execution time in milliseconds.</comment>
      </elem>

      <elem name="serviceResults" multiplicity="0..*" type="ServiceResults">
        <comment>Results processed by a specified service.</comment>
      </elem>

      <elem name="uuidData" multiplicity ="0..*" type="UUID" >
        <comment>Zero or more UUIDs identifying the survey test data used in this result set.</comment>
      </elem>
    </struct>

    <!-- 
    *******************************************************
    Analyzer API
    *******************************************************
    -->
    <interface name="Analyzer">
      <comment>Interface for performance analysis functions with ILP.</comment>

      <operation name="Execute">
        <comment>
          Operation executes the provided specification.
        </comment>
        <input name="input" type="Tensor.InputBase"  sid="0x1060">
          
          <elem name="returnResults" multiplicity ="1" type="bool" default ="true">
            <comment>Optional, determines if results should be returned to caller on completion.  By default, this is true. For long processing sessions
            the connection timeout may occur before results are returned.  In that case check the published results.</comment>
          </elem>
          
          <elem name="saveResults" multiplicity ="1" type="bool" default ="false">
            <comment>Optional, determines if processing results should be stored</comment>
          </elem>
          
          <elem name="publishResults" multiplicity ="1" type="bool" default ="false">
            <comment>Optional, publishes the results for additional downstream processing.</comment>
          </elem>
          
          <elem name="maxBatch" multiplicity ="1" type="uint16" default ="1">
            <tag name="unit" value="records"/> 
            <comment>The maximum batch of records that may be processed at one time.  The default is 1, only one record may be processed at a time.
            The system may place limits on the batch size and interval so as maximum throughput limit is not exceeded for any particular service.</comment>
          </elem>          

          <elem name="msecInterval" multiplicity ="1" type="uint32" default ="100">
            <tag name="unit" value="msec"/>              
            <comment>The minimum processing interval in msec units.  This specifies the interval between batches.  For development systems these values should be set relatively
            high (e.g. 100 msec) to minimize operational overhead on services.  The default is 100 msec. The system may place limits on the batch size and interval so as maximum 
            throughput limit is not exceeded for any particular service.</comment>
          </elem>          

          <elem name="spec" multiplicity="1" type="Specification">
            <comment>The test specification to execute.</comment>
          </elem>
          
        </input>
        <output name="output" type="Tensor.OutputBase" sid="0x1061">
          
          <comment>Test Execution output. Note if not wanting results, the execute method will return early with a processing result code.</comment>

          <elem name="results" multiplicity="0..*" type="DataSetResults">
            <comment>The result test data set if the 'returnResults' option was selected on input.</comment>
          </elem>
          
          <elem name="dataSetsFiltered" multiplicity="0..*" type="DataSet">
            <comment>The resultant requested filtered data sets if any.</comment>
          </elem>
          
        </output>
      </operation>

      <operation name="Services">
        <comment>
          Operation returns the list of calculation service URIs available.
        </comment>
        <input name="input" type="Tensor.InputBase"  sid="0x1062">
        </input>
        <output name="output" type="Tensor.OutputBase" sid="0x1063">
          <elem name="uriServices" multiplicity = "0..*" type="Tensor.uri">
              <comment>One or more services to use to process the specified data sets.   Analysis can comprise multiple services 
              processing the datasets and producing reports that provide a comparative performance. 
              </comment>
          </elem>      
        </output>
      </operation>
    </interface>

    <!-- 
    *******************************************************
    Analysis Reporting Results API
    *******************************************************
    -->
    <interface name="Report">
      <comment>Interface for receiving analysis results.</comment>

      <operation name="Results">
        <comment>
          Operation Reports analysis results.
        </comment>
        <input name="input" type="DataSetResults" sid="0x1062"/>
      </operation>
    </interface>

  </namespace>
</specification>