31 #ifndef DW_PLANNING_SAFETYFORCEFIELD_H_ 32 #define DW_PLANNING_SAFETYFORCEFIELD_H_ 81 #define DW_SAFETY_FORCE_FIELD_MAX_NUM_ACTORS_LIMIT 150 82 #define DW_SAFETY_FORCE_FIELD_NUM_SLICES 16 83 #define DW_SAFETY_FORCE_FIELD_METRICS_MAX_NUM_COLLIDING_OBJECTS 200 84 #define DW_SAFETY_FORCE_FIELD_NUM_VERTICES_EXPANDING_CLAIMED_SETS 6 85 #define DW_SAFETY_FORCE_FIELD_MAX_NUM_CLOSE_ACTORS 10 249 dwSafetyForceFieldHandle_t handle);
265 uint32_t numObjectArrays,
268 dwSafetyForceFieldHandle_t handle);
296 dwSafetyForceFieldHandle_t handle);
308 dwSafetyForceFieldHandle_t handle);
339 uint32_t constraintBits);
371 dwSafetyForceFieldHandle_t handle);
390 dwSafetyForceFieldHandle_t handle);
398 #endif // DW_PLANNING_SAFETYFORCEFIELD_H_ float32_t margin
distance margin in [m]
bool forceStraight
true to use straight claimed sets, i.e. the safety procedure has no lateral movement ...
float32_t collisionTime
time of collision of actor with ego, -1.0 if there is no collision
NVIDIA DriveWorks API: Core Types
dwSafetyForceFieldControl Control parameters used in Safety Force Field.
DW_API_PUBLIC dwStatus dwSafetyForceField_getCUDAStream(cudaStream_t *stream, dwSafetyForceFieldHandle_t handle)
Get the cuda stream to be used.
#define DW_SAFETY_FORCE_FIELD_NUM_VERTICES_EXPANDING_CLAIMED_SETS
float float32_t
Specifies POD types.
struct dwImageObject * dwImageHandle_t
NVIDIA DriveWorks API: Egomotion Methods
NVIDIA DriveWorks API: World Module
Request for safety force field auto engagement.
Defines a two-element single-precision floating-point vector.
uint32_t objectSensorId
sensor IDs of the actor
DW_API_PUBLIC dwStatus dwSafetyForceField_setEgomotion(dwEgomotionConstHandle_t egomotion, dwSafetyForceFieldHandle_t handle)
Bind egomotion model handle.
NVIDIA DriveWorks API: VehicleIO car controller
bool activationRequest
Activation request.
dwSafetyForceFieldCombinationType
dwSafetyForceFieldCombinationType How control constraints are combined
DW_API_PUBLIC dwStatus dwSafetyForceField_initDefaultParams(dwSafetyForceFieldParams *params)
Initialize module parameters with default values.
uint32_t totalNumSequencesWithActuation
number of continuous sequences of frames with altered controls
float32_t collisionEMA
exponential moving average of collision number to visualize the average false positives and focus mor...
float32_t desiredLongitudinalAccel
SFF chosen acceleration minus vdc attempted acceleration.
uint32_t numClaimedSets
Number of claimed sets reported.
bool useRoadStructure
true if structured safety procedures should be used
DW_API_PUBLIC dwStatus dwSafetyForceField_initializeControlConstraints(dwSafetyForceFieldControlConstraints *c)
Helper function to initialize control constraints.
DW_API_PUBLIC dwStatus dwSafetyForceField_initializeMultiControlConstraints(dwSafetyForceFieldMultiControlConstraints *c)
Helper function to initialize multi control constraints.
NVIDIA DriveWorks API: Image Conversion and Streaming Functionality
bool useGPU
use true if cuda optimization should be used
dwSafetyForceFieldConeType
uint32_t totalNumFramesWithActuation
number of frames that altered the controls checked
float32_t minConfidence
object velocity confidence threshold.
dwSafetyForceFieldMultiControlConstraints An array of Safety Force Field control constraints.
uint32_t actuationSequenceLength
length of ongoing continuous sequence of frames with altered controls
float32_t maxStopTime
Time horizon of the SFF simulation.
dwVehicle vehicleProps
ego vehicle properties
dwStatus
Status definition.
struct dwSafetyForceFieldObject const * dwConstSafetyForceFieldHandle_t
float32_t maxClearance
always filter objects with absolute clearance above this threshold [m]
uint64_t objectId
object IDs of the actor
NVIDIA DriveWorks API: LaneGraph
uint32_t numActors
Number of actors reported.
DW_API_PUBLIC dwStatus dwSafetyForceField_getMetrics(dwSafetyForceFieldMetrics *metrics, dwSafetyForceFieldHandle_t handle)
Getter of statistics of safety force field collisions.
DW_API_PUBLIC dwStatus dwSafetyForceField_process(dwObjectArray **objectsList, uint32_t numObjectArrays, const dwVehicleIOState *vioState, const dwLaneGraph *lg, dwSafetyForceFieldHandle_t handle)
Main process.
int64_t dwTime_t
Specifies a timestamp unit, in microseconds.
DW_API_PUBLIC dwStatus dwSafetyForceField_reset(dwSafetyForceFieldHandle_t handle)
Reset the safety force field module.
float32_t controlImageEnd
left boundary of the cone of safe controls in radians, depending on cone type
dwSafetyForceFieldConeType controlImageConeType
Shape of the cone of safe controls.
DW_API_PUBLIC dwStatus dwSafetyForceField_setCUDAStream(cudaStream_t stream, dwSafetyForceFieldHandle_t handle)
Set the cuda stream to be used.
DW_API_PUBLIC dwStatus dwSafetyForceField_release(dwSafetyForceFieldHandle_t handle)
Release the safety force field module.
dwVector2f collisionPoint
2D collision point in rig; only valid if collisionTime is positive
uint32_t totalNumFramesWithCollision
number of frames that had predicted collisions
struct dwEgomotionObject const * dwEgomotionConstHandle_t
DW_API_PUBLIC dwStatus dwSafetyForceField_getState(dwSafetyForceFieldState *state, const dwSafetyForceFieldControl *beforeActuation, const dwSafetyForceFieldControl *afterActuation, bool relative, dwSafetyForceFieldHandle_t handle)
Getter of SFF state for roadcast.
uint32_t totalNumFrames
number of frames processed
DW_API_PUBLIC dwStatus dwSafetyForceField_getControlImage(dwImageHandle_t *img, const dwSafetyForceFieldControl *beforeActuation, const dwSafetyForceFieldControl *afterActuation, float32_t steeringLimit, float32_t minAccel, float32_t maxAccel, float32_t steerRange, float32_t accelRange, dwSafetyForceFieldHandle_t handle)
Control image getter.
Lane graph defined by a container of dwLaneGraphLane objects and qualifier.
float32_t actuationEMA
exponential moving average of actuation number to visualize the average false positives and focus mor...
Homogeneous array of structs.
#define DW_SAFETY_FORCE_FIELD_METRICS_MAX_NUM_COLLIDING_OBJECTS
float32_t desiredLateralAccel
SFF chosen lateral acceleration minus vdc attempted lateral acceleration.
uint32_t numCollidingObjects
number of objects in current frame that ego has predicted collision with
bool filterActors
true to filter actors by keeping the ones that are close to ego-vehicle and have high velocity confid...
float32_t longitudinalSafetyForce
longitudinal force from this collision point; only valid if collisionTime is positive ...
dwTime_t timeStamp
Timestamp for request.
float32_t lateralSafetyForce
lateral force from this collision point; only valid if collisionTime is positive
uint32_t totalNumSequencesWithCollision
number of continuous sequences of frames with predicted collisions
struct dwContextObject * dwContextHandle_t
Context handle.
#define DW_SAFETY_FORCE_FIELD_NUM_SLICES
struct dwSafetyForceFieldObject * dwSafetyForceFieldHandle_t
#define DW_SAFETY_FORCE_FIELD_MAX_NUM_ACTORS_LIMIT
DW_API_PUBLIC dwStatus dwSafetyForceField_combineControlConstraints(dwSafetyForceFieldMultiControlConstraints *out, const dwSafetyForceFieldControlConstraints *ins, uint32_t inCount, dwSafetyForceFieldCombinationType type, uint32_t constraintBits)
Helper function to combine control constraints.
uint32_t maxNumActors
max number of input objects
uint32_t collisionSequenceLength
length of ongoing continuous sequence of frames with predicted collisions
bool expandClaimedSets
true to inflate claimed sets that represent reaction time, uncertainties, etc.
bool restrictToMoving
true to ignore obstacles that are not moving (requires valid obstacleState)
float32_t controlImageStart
right boundary of the cone of safe controls in radians, depending on cone type
DW_API_PUBLIC dwStatus dwSafetyForceField_getControlConstraints(dwSafetyForceFieldControlConstraints *constraints, dwSafetyForceFieldHandle_t handle)
Getter of the SFF control constraints for actuation for safety.
DW_API_PUBLIC dwStatus dwSafetyForceField_initialize(dwSafetyForceFieldHandle_t *handle, const dwSafetyForceFieldParams *params, dwContextHandle_t context)
Initialize a safety force field module.
dwSafetyForceFieldControlConstraints A collection of constraints, which is derived from Safety Force ...
#define DW_SAFETY_FORCE_FIELD_MAX_NUM_CLOSE_ACTORS
for roadcast
NVIDIA DriveWorks API: Core Status Methods
Properties of the vehicle.