onvif / specs

ONVIF Network Interface Specifications
Other
325 stars 87 forks source link

Extend LPR event to include Speed and Direction of the detected object #411

Closed bsriramprasad closed 5 days ago

bsriramprasad commented 3 months ago
  1. Extend the License plate recognition event to include additional data of the recognized license plate
    • Speed in unit of m/sec
    • Direction expressed as tt:ObjectMovement
    • tt:ObjectMovement enum defined
  2. Extend the generic recognition event output parameters to include
kieran242 commented 3 months ago

I would be willing to approve this as I feel all the changes outside of the tt:Direction type are all good and useful. The proposed updates are set to optional so no backward compatibility problems. please just respond with comment on this issue as I agree with @jflevesque-genetec.

bsriramprasad commented 3 months ago

Here is the proposal to extend the existing tt:Direction keeping backward compatibility.

But I am only concerned as this kind of mechanism of using "union" of extending enums has no precedence in ONVIF before and would like to know if there are better mechanisms than what I could see/find.

<xs:simpleType name="Direction">
    <xs:union memberTypes="tt:ExtendedDirection"/>
</xs:simpleType>

<xs:simpleType name="ExtendedDirection">
  <xs:restriction base="xs:string">
      <xs:enumeration value="Left"/>
      <xs:enumeration value="Right"/>
      <xs:enumeration value="Any"/>
      <!-- Add new values -->
      <xs:enumeration value="TowardsSensor"/>
      <xs:enumeration value="AwayFromSensor"/>
  </xs:restriction>
</xs:simpleType>
HansBusch commented 3 months ago

While left and right are generic terms towardsSensor and AwayFromSensor include a noun. Is the camera image sensor meant or what does sensor refer to? If camera image sensor is meant, then towards sensor would mean approaching. If the sensor is a polygon area then probably entering would be the appropriate word.

Agree with your concerns regarding mixing line crossing with this new definition. Let's first find out what you want to define.

araspapadelis commented 3 months ago

While left and right are generic terms towardsSensor and AwayFromSensor include a noun. Is the camera image sensor meant or what does sensor refer to? If camera image sensor is meant, then towards sensor would mean approaching. If the sensor is a polygon area then probably entering would be the appropriate word.

Agree with your concerns regarding mixing line crossing with this new definition. Let's first find out what you want to define.

The word sensor in this case refers to the camera, not a polygon area. An alternative phrasing could be "approaching" and "leaving".

HansBusch commented 2 months ago

This is a really tricky topic. In the two-dimensional plane entering and leaving are will defined events that happen exactly when an object crosses the boundary of a polygon. Looking at the third dimension things get more tricky as in your case the object stays inside the boundary for all the time but just gets closer or more far away over time. Note that both things can happen at the same time and additionally the object also may role. So worst case we have a three dimensional flight path plus three rotation vectors.

Not sure whether this can be simplified to something like

venki5685 commented 2 months ago

"approaching" and "leaving" makes sense for me in the context of camera sensor where vehicle approaching or leaving the camera sensor.

araspapadelis commented 2 months ago

Another suggestion:

bsriramprasad commented 2 months ago

2024-05-16