TrackObject
class TrackObject extendsJob implementsShouldQueue
Attempts to track an obect in a video. The object is initially defined by a video annotation. The annotation will be updated with the positions determined with the object tracking method.
Traits
Properties
protectedVideoAnnotation | $annotation | The annotation that defines the initial object to track. | |
protectedbool | $deleteWhenMissingModels | Ignore this job if the annotation does not exist any more. | |
int | $tries | The number of times the job may be attempted. |
Methods
Execute the job.
Execute the object tracking method and get the resulting annotation key frames.
Get the path to to input file for the object tracking script.
Create the JSON file that is the input for the object tracking script.
Delete a file if it exists.
Get the path to to output file for the object tracking script.
Execute a Python script.
Get the coordinates and dimensions of the start window for the object tracking script.
Get the points of a keyframe depending on the annotation shape.
Details
at line49
__construct(VideoAnnotation$annotation)
Create a new instance.
at line59
void
handle()
Execute the job.
at line90
void
failed(Exception$exception)
The job failed to process.
at line103
protectedarray
getTrackingKeyframes(VideoAnnotation$annotation)
Execute the object tracking method and get the resulting annotation key frames.
at line137
protectedstring
getInputJsonPath(VideoAnnotation$annotation)
Get the path to to input file for the object tracking script.
at line150
protectedstring
createInputJson(VideoAnnotation$annotation,string$videoPath)
Create the JSON file that is the input for the object tracking script.
at line170
protected
maybeDeleteFile(string$path)
Delete a file if it exists.
at line184
protectedstring
getOutputJsonPath(VideoAnnotation$annotation)
Get the path to to output file for the object tracking script.
at line196
protectedThe
python(string$command)
Execute a Python script.
at line219
protectedarray
getStartWindow(VideoAnnotation$annotation)
Get the coordinates and dimensions of the start window for the object tracking script.
at line262
protectedarray
getPointsFromKeyframe(VideoAnnotation$annotation,array$keyframe)
Get the points of a keyframe depending on the annotation shape.