Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DetectionBuffer ¶
type DetectionBuffer interface { // Insert new a frame represented by the index and the detection status. Append(index int, detected bool) // Convert the detections collection into a ascending sorted slice of frames indexes. Resolve() []int }
A data structure that stores the detections and allows for automatic correction of missed detections thanks to a candidate buffer.
func CreateDetectionBuffer ¶
func CreateDetectionBuffer() DetectionBuffer
Create a new detection buffer instance with the candidate buffer size set to four.
type Detector ¶
Detector instance that is able to perform a search after ligntning strikes on a video file.
func CreateDetector ¶
func CreateDetector(renderer render.Renderer, options DetectorOptions) (Detector, error)
Create a new video lightning detector instance with the specified options.
type DetectorOptions ¶
type DetectorOptions struct { AutoThresholds bool BrightnessDetectionThreshold float64 ColorDifferenceDetectionThreshold float64 BinaryThresholdDifferenceDetectionThreshold float64 MovingMeanResolution int32 ExportCsvReport bool ExportJsonReport bool ExportChartReport bool SkipFramesExport bool Denoise bool FrameScalingFactor float64 }
Structure representing the options for the detector.
func GetDefaultDetectorOptions ¶
func GetDefaultDetectorOptions() DetectorOptions
Return the default detector options.
func (*DetectorOptions) AreValid ¶
func (options *DetectorOptions) AreValid() (bool, string)
Return a boolean value representing if the detector options are valid. If any validation errors occured a message will be stored in the string return value. TODO: MovingMeanResolution validation >1