irSensor

Generate infrared detections for tracking scenario

Description

The irSensor System object™ creates a statistical model for generating detections using infrared sensors. You can use the irSensor object in a scenario that models moving and stationary platforms using trackingScenario. The sensor can simulate real detections with added random noise and also generate false alarm detections. In addition, you can use this object to create input to trackers such as trackerGNN, trackerJPDA or trackerTOMHT.

This object enables you to configure a mechanically scanning sensor. An infrared scanning sensor changes the look angle between updates by stepping the mechanical position of the beam in increments of the angular span specified in the FieldOfView property. The infrared sensor scans the total region in azimuth and elevation defined by the MechanicalScanLimits property. If the scanning limits for azimuth or elevation are set to [0 0], no scanning is performed along that dimension for that scan mode. Also, if the maximum scan rate for azimuth or elevation is set to zero, no scanning is performed along that dimension.

To generate infrared detections:

  1. Create the irSensor object and set its properties.

  2. Call the object with arguments, as if it were a function.

To learn more about how System objects work, see What Are System Objects? (MATLAB).

Creation

Description

sensor = irSensor(SensorIndex) creates an infrared detection generator object with a specified sensor index, SensorIndex, and default property values.

sensor = irSensor(SensorIndex,'No scanning') is a convenience syntax that creates an irSensor that stares along the sensor boresight direction. No mechanical scanning is performed. This syntax sets the ScanMode property to 'No scanning'.

sensor = irSensor(SensorIndex,'Raster') is a convenience syntax that creates an irSensor object that mechanically scans a raster pattern. The raster span is 90° in azimuth from –45° to +45° and in elevation from the horizon to 10° above the horizon. See Convenience Syntaxes for the properties set by this syntax.

sensor = irSensor(SensorIndex,'Rotator') is a convenience syntax that creates an irSensor object that mechanically scans 360° in azimuth by electronically rotating the sensor at a constant rate. When you set HasElevation to true, the infrared sensor mechanically points towards the center of the elevation field of view. See Convenience Syntaxes for the properties set by this syntax.

sensor = irSensor(SensorIndex,'Sector') is a convenience syntax to create an irSensor object that mechanically scans a 90° azimuth sector from –45° to +45°. Setting HasElevation to true, points the infrared sensor towards the center of the elevation field of view. Beams are stacked mechanically to process the entire elevation spanned by the scan limits in a single dwell. See Convenience Syntaxes for the properties set by this syntax.

sensor = irSensor(___,Name,Value) sets properties using one or more name-value pairs after all other input arguments. Enclose each property name in quotes. For example, irSensor(1,'UpdateRate',1,'CutoffFrequency',20e3) creates an infrared sensor that reports detections at an update rate of 1 Hz and a cut off frequency of 20 kHz. If you specify the sensor index using the SensorIndex property, you can omit the SensorIndex input.

Properties

expand all

Unless otherwise indicated, properties are nontunable, which means you cannot change their values after calling the object. Objects lock when you call them, and the release function unlocks them.

If a property is tunable, you can change its value at any time.

For more information on changing property values, see System Design in MATLAB Using System Objects (MATLAB).

Unique sensor identifier, specified as a positive integer. This property distinguishes detections that come from different sensors in a multi-sensor system. When creating an irSensor system object, you must either specify the SensorIndex as the first input argument in the creation syntax, or specify it as the value for the SensorIndex property in the creation syntax.

Example: 2

Data Types: double

Sensor update rate, specified as a positive scalar. This interval must be an integer multiple of the simulation time interval defined by trackingScenario. The trackingScenario object calls the infrared sensor at simulation time intervals. The sensor generates new detections at intervals defined by the reciprocal of the UpdateRate property. Any update requested to the sensor between update intervals contains no detections. Units are in hertz.

Example: 5

Data Types: double

Scanning mode of infrared sensor, specified as 'Mechanical' or 'No scanning'. When set to 'Mechanical', the sensor scans mechanically across the azimuth and elevation limits specified by the MechanicalScanLimits property. The scan positions step by the sensor's field of view between dwells. When set to 'No scanning', no scanning is performed by the sensor.

Example: 'No scanning'

Data Types: char

Sensor location on platform, specified as a 1-by-3 real-valued vector. This property defines the coordinates of the sensor with respect to the platform origin. The default value specifies that the sensor origin is at the origin of its platform. Units are in meters.

Example: [.2 0.1 0]

Data Types: double

Orientation of the sensor with respect to the platform, specified as a three-element real-valued vector. Each element of the vector corresponds to an intrinsic Euler angle rotation that carries the body axes of the platform to the sensor axes. The three elements describes the rotations around the z-, y-, and x-axes sequentially. Units are in degrees.

Example: [10 20 -15]

Data Types: double

Fields of view of sensor, specified as a 2-by-1 vector of positive real values, [azfov;elfov]. The field of view defines the total angular extent spanned by the sensor. Each component must lie in the interval (0,180]. Targets outside of the field of view of the sensor will not be detected. Units are in degrees.

Example: [14;70]

Data Types: double

Maximum mechanical scan rate, specified as a nonnegative scalar or real-valued 2-by-1 vector with nonnegative entries.

When HasElevation is true, specify the scan rate as a 2-by-1 column vector of nonnegative entries [maxAzRate; maxElRate]. maxAzRate is the maximum scan rate in azimuth and maxElRate is the maximum scan rate in elevation.

When HasElevation is false, specify the scan rate as a nonnegative scalar representing the maximum mechanical azimuth scan rate.

Scan rates set the maximum rate at which the infrared sensor can mechanically scan. The sensor sets its scan rate to step the mechanical angle by the field of regard. If the required scan rate exceeds the maximum scan rate, the maximum scan rate is used. Units are degrees per second.

Example: [5;10]

Dependencies

To enable this property, set the ScanMode property to 'Mechanical'.

Data Types: double

Angular limits of mechanical scan directions of sensor, specified as a real-valued, 1-by-2 row vector or a real-valued 2-by-2 matrix. The mechanical scan limits define the minimum and maximum mechanical angles the sensor can scan from its mounted orientation.

When HasElevation is true, the scan limits take the form [minAz maxAz; minEl maxEl]. minAz and maxAz represent the minimum and maximum limits of the azimuth angle scan. minEl and maxEl represent the minimum and maximum limits of the elevation angle scan. When HasElevation is false, the scan limits take the form [minAz maxAz]. If you specify the scan limits as a 2-by-2 matrix but set HasElevation to false, the second row of the matrix is ignored.

Azimuthal scan limits cannot span more than 360° and elevation scan limits must lie within the closed interval [-90° 90°]. Units are in degrees.

Example: [10 90;0 85]

Dependencies

To enable this property, set the ScanMode property to 'Mechanical'.

Data Types: double

This property is read-only.

Current mechanical scan angle, returned as a scalar or real-valued 2-by-1 vector. When HasElevation is true, the scan angle takes the form [Az; El]. Az and El represent the azimuth and elevation scan angles, respectively, relative to the mounted angle of the sensor on the platform. When HasElevation is false, the scan angle is a scalar representing the azimuth scan angle.

Data Types: double

This property is read-only.

Look angle of sensor, specified as a scalar or real-valued 2-by-1 vector. Look angle depends on the mechanical angle set in the ScanMode property.

ScanModeLookAngle
'Mechanical'MechanicalAngle
'No scanning'0

When HasElevation is true, the look angle takes the form [Az;El]. Az and El represent the azimuth and elevation look angles, respectively. When HasElevation is false, the look angle is a scalar representing the azimuth look angle.

Lens diameter, specified as a positive scalar. Units are in meters.

Example: 0.1

Data Types: double

Focal length of sensor circular lens, specified as a scalar. The focal length in pixels is f = F s, where F is the focal length in millimeters and s is the number of pixels per millimeter.

Example: 500

Data Types: double

Number of infrared detectors in the sensor imaging plane, specified as a positive, real-valued, two-element row vector. The first element defines the number of rows in the imaging plane and the second element defines the number of columns in the imaging plane. The number of rows corresponds to the sensor elevation resolution and the number of columns corresponds to the sensor azimuth resolution.

Example: [500 750]

Data Types: double

Cut off frequency of the sensor modulation transfer function (MTF), specified as a positive scalar. Units are in hertz.

Example: 30.5e3

Dependencies

To enable this property, set the ScanMode property to 'Mechanical'.

Data Types: double

Area of an infrared detector element/pixel, specified as a positive scalar. Units are in square-meters.

Example: 3.0e-5

Data Types: double

Specific detectivity of the detector material, specified as a positive scalar. Units are cm-sqrt(Hz)/W.

Example: .9e10

Data Types: double

Noise equivalent bandwidth of sensor, specified as a positive scalar. Units are in Hz.

Example: 100

Data Types: double

Rate of false alarm report in each resolution cell, specified as a positive scalar in the range of [10–7,10–3]. Units are dimensionless. Resolution cells are determined from the AzimuthResolution property and the optionally enabled ElevationResolution property.

Example: 1e-5

Data Types: double

This property is read-only.

Azimuth resolution of the sensor, specified as a positive scalar. The azimuth resolution defines the minimum separation in azimuth angle at which the senor can distinguish two targets. The azimuth resolution is derived from the focal length of the lens and the number of columns in the detector's imaging plane. Units are in degrees.

Data Types: double

This property is read-only.

Elevation resolution of the sensor, specified as a positive scalar. The elevation resolution defines the minimum separation in elevation angle at which the senor can distinguish two targets. The elevation resolution is derived from the focal length of the lens and the number of rows in the detector's imaging plane. Units are in degrees.

Dependencies

To enable this property, set the HasElevation property to true.

Data Types: double

Azimuth bias fraction of the sensor, specified as a nonnegative scalar. The azimuth bias is expressed as a fraction of the azimuth resolution specified in AzimuthResolution. This value sets a lower bound on the azimuthal accuracy of the sensor. This property only applies for modes where the sensor is scanning. The value is dimensionless.

Data Types: double

Elevation bias fraction of the sensor, specified as a nonnegative scalar. Elevation bias is expressed as a fraction of the elevation resolution specified by the value of the ElevationResolution property. This value sets a lower bound on the elevation accuracy of the sensor. This property only applies for modes where the sensor is scanning. The value is dimensionless.

Dependencies

To enable this property, set the HasElevation property to true.

Data Types: double

Enable the sensor to measure target elevation angles and to scan in elevation, specified as false or true. Set this property to true to model an infrared sensor that can estimate target elevation and scan in elevation.

Data Types: logical

Enable the sensor to return the azimuth and elevation size or span of the target in the reported detections, specified as false or true. If this property is set to false, then the only azimuth and elevation locations instead of their angular extent are reported in the detections.

Data Types: logical

Enable the optional input argument that passes the current estimate of the sensor platform pose to the sensor, specified as false or true. When true, pose information is added to the MeasurementParameters structure of the reported detections. Pose information lets tracking and fusion algorithms estimate the state of the target detections in the north-east-down (NED) frame.

Data Types: logical

Enable addition of noise to senor sensor measurements, specified as true or false. Set this property to true to add noise to the measurements. Otherwise, the measurements have no noise. Note that the reported measurement noise covariance is not dependent on this property and is always representative of the noise that will be added when HasNoise is set to true.

Data Types: logical

Enable creating false alarm sensor measurements, specified as true or false. Set this property to true to report false alarms. Otherwise, only actual detections are reported.

Data Types: logical

Enable occlusion from extended objects, specified as true or false. Set this property to true to model occlusion from extended objects. Two types of occlusion (self occlusion and inter object occlusion) are modeled. Self occlusion occurs when one side of an extended object occludes another side. Inter object occlusion occurs when one extended object stands in the line of sight of another extended object or a point target. Note that both extended objects and point targets can be occluded by extended objects, but a point target cannot occlude another point target or an extended object.

Set this property to false to disable occlusion of extended objects. This will also disable the merging of objects whose detections share a common sensor resolution cell, which gives each object in the tracking scenario an opportunity to generate a detection.

Data Types: logical

Minimum image size for classification, specified as a positive integer. MinClassificationArea specifies the minimum area (in square pixels) used to decide whether the sensor recognizes the detection as a classified object. The irSensor tries to enclose the extent detection using a minimum rectangular bounding box (along the azimuth and elevation directions) in the sensor image plane. If the area of the minimum bounding box is less than the value given by the MinClassificationArea property, then the reported ClassID is zero in the returned objectDetection for that detection. Otherwise, the reported ClassID is obtained from the ClassID of the corresponding target input.

Data Types: double

Maximum allowed occlusion, specified as a real scalar on the interval of [0,1). The property specifies the ratio of the occluded area relative to the total area of a target's bounding box. If the occluded area ratio is larger than the value specified by the MaxAllowedOccusion property, the occluded target will not be detected.

Data Types: double

Source of maximum number of detections reported by the sensor, specified as 'Auto' or 'Property'. When this property is set to 'Auto', the sensor reports all detections. When this property is set to 'Property', the sensor reports detections up to the number specified by the MaxNumDetections property.

Data Types: char

Maximum number of detections can be reported by the sensor, specified as a positive integer. Detections are reported in order of distance to the sensor until the maximum number is reached.

Dependencies

To enable this property, set the MaxNumDetectionsSource property to 'Property'.

Data Types: double

Usage

Description

dets = sensor(targets,simTime) creates infrared detections, dets, from sensor measurements taken of targets at the current simulation time, simTime. The sensor can generate detections for multiple targets simultaneously.

example

dets = sensor(targets,ins,simTime) also specifies the INS estimated pose information, ins, for the sensor platform. INS information is used by tracking and fusion algorithms to estimate the target positions in the NED frame.

To enable this syntax, set the HasINS property to true.

[dets,numDets,config] = sensor(___) also returns the number of valid detections reported, numValidDets, and the configuration of the sensor, config, at the current simulation time.

Input Arguments

expand all

Tracking scenario target poses, specified as a structure or array of structures. Each structure corresponds to a target. You can generate this structure using the targetPoses method of a platform. You can also create such a structure manually. The table shows the required fields of the structure:

FieldDescription
PlatformID

Unique identifier for the platform, specified as a scalar positive integer. This is a required field with no default value.

ClassID

User-defined integer used to classify the type of target, specified as a nonnegative integer. Zero is reserved for unclassified platform types and is the default value.

Position

Position of target in platform coordinates, specified as a real-valued, 1-by-3 vector. This is a required field with no default value. Units are in meters.

Velocity

Velocity of target in platform coordinates, specified as a real-valued, 1-by-3 vector. Units are in meters per second. The default is [0 0 0].

Acceleration

Acceleration of target in platform coordinates specified as a 1-by-3 row vector. Units are in meters per second-squared. The default is [0 0 0].

Orientation

Orientation of the target with respect to platform coordinates, specified as a scalar quaternion or a 3-by-3 rotation matrix. Orientation defines the frame rotation from the platform coordinate system to the current target body coordinate system. Units are dimensionless. The default is quaternion(1,0,0,0).

AngularVelocity

Angular velocity of target in platform coordinates, specified as a real-valued, 1-by-3 vector. The magnitude of the vector defines the angular speed. The direction defines the axis of clockwise rotation. Units are in degrees per second. The default is [0 0 0].

The values of the Position, Velocity, and Orientation fields are defined with respect to the platform coordinate system.

Current simulation time, specified as a positive scalar. The trackingScenario object calls the infrared sensor at regular time intervals. The sensor generates new detections at intervals defined by the UpdateInterval property. The value of the UpdateInterval property must be an integer multiple of the simulation time interval. Updates requested from the sensor between update intervals contain no detections. Units are in seconds.

Example: 10.5

Data Types: double

Sensor platform pose obtained from the inertial navigation system (INS), specified as a structure.

Platform pose information from an inertial navigation system (INS) is a structure which has these fields:

FieldDefinition
Position

Position of the GPS receiver in the local NED coordinate system, specified as a real-valued 1-by-3 vector. Units are in meters.

Velocity

Velocity of the GPS receiver in the local NED coordinate system, specified as a real-valued 1-by-3 vector. Units are in meters per second.

Orientation

Orientation of the INS with respect to the local NED coordinate system, specified as a scalar quaternion or a 3-by-3 real-valued orthonormal frame rotation matrix. Defines the frame rotation from the local NED coordinate system to the current INS body coordinate system. This is also referred to as a "parent to child" rotation.

Dependencies

To enable this argument, set the HasINS property to true.

Data Types: struct

Interfering or jamming signal, specified as a structure.

Dependencies

To enable this argument, set the HasInterference property to true.

Data Types: double
Complex Number Support: Yes

Output Arguments

expand all

Sensor detections, returned as a cell array of objectDetection objects. Each object has these properties:

PropertyDefinition
TimeMeasurement time
MeasurementObject measurements
MeasurementNoiseMeasurement noise covariance matrix
SensorIndexUnique ID of the sensor
ObjectClassIDObject classification
MeasurementParametersParameters used by initialization functions of nonlinear Kalman tracking filters
ObjectAttributesAdditional information passed to tracker

Measurement and MeasurementNoise are reported in the coordinate system specified by the DetectionCoordinates property.

Number of detections reported, returned as a nonnegative integer.

  • When the MaxNumDetectionsSource property is set to 'Auto', numDets is set to the length of dets.

  • When the MaxNumDetectionsSource property is set to 'Property', dets is a cell array with length determined by the MaxNumDetections property. No more than MaxNumDetections number of detections are returned. If the number of detections is fewer than MaxNumDetections, the first numDets elements of dets hold valid detections. The remaining elements of dets are set to the default value.

Data Types: double

Current sensor configuration, specified as a structure. This output can be used to determine which objects fall within the sensor beam during object execution.

FieldDescription
SensorIndex

Unique sensor index

IsValidTime

Valid detection time, returned as 0 or 1. IsValidTime is 0 when detection updates are requested at times that are between update intervals specified by UpdateInterval.

IsScanDone

IsScanDone is true when the sensor has completed a scan.

FieldOfView

Field of view of sensor determines which objects fall within the sensor beam during object execution. The field of view is defined as a 2-by-1 vector of positive real values, [azfov;elfov].

MeasurementParameters

MeasurementParameters is an array of structures containing the coordinate frame transforms needed to transform positions and velocities in the top-level frame to the current sensor frame.

Data Types: struct

Object Functions

To use an object function, specify the System object as the first input argument. For example, to release system resources of a System object named obj, use this syntax:

release(obj)

expand all

stepRun System object algorithm
releaseRelease resources and allow changes to System object property values and input characteristics
resetReset internal states of System object

Examples

expand all

Detect a target with an infrared sensor.

First create a target structure.

tgt = struct( ...
    'PlatformID',1, ...
    'Position',[10e3 0 0], ...
    'Speed',900*1e3/3600);

Then create an IR sensor.

sensor = irSensor(1);

Generate detection from target.

time = 0;
[dets,numDets,config] = sensor(tgt,time)
dets = 1x1 cell array
    {1x1 objectDetection}

numDets = 1
config = struct with fields:
              SensorIndex: 1
              IsValidTime: 1
               IsScanDone: 0
              FieldOfView: [64.0108 64.0108]
    MeasurementParameters: [1x1 struct]

More About

expand all

Extended Capabilities

See Also

Objects

Functions

System Objects

Introduced in R2018b