processor

package
v1.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 30, 2024 License: BSD-3-Clause Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ScoreSimilar        float32 = 0.001 // score to assign for similar images
	ScoreDifferent      float32 = 1.0   // score to assign for different images
	SimilarityThreshold float32 = 0.5   // maximum score for similar images
)
View Source
const (
	DefaultChrominanceTolerance = 0.3
	DefaultProportionTolerance  = 10.0
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Processor

type Processor struct {
	QuietMode    bool          // be really quiet (only show warnings and errors)
	OutputWriter *bufio.Writer // where to write the report (nil means stdout)

	UseAbsolutePaths     bool // When true filenames will be stored in the state with absolute paths
	IgnoreFalsePositives bool // Trat false positives as matches

	ChrTolerance  float64 // Luma and Chrominance tolerance
	PropTolerance float64 // proportion tolerance
	// contains filtered or unexported fields
}

func MakeProcessor

func MakeProcessor(numWorkers int, stateDirectory string, logger *logrus.Logger) *Processor

func (*Processor) CompactState added in v1.1.0

func (proc *Processor) CompactState() error

func (*Processor) DebugDump

func (proc *Processor) DebugDump()

func (*Processor) GenerateReport

func (proc *Processor) GenerateReport()

func (*Processor) Process

func (proc *Processor) Process(directories []string) error

func (*Processor) SetExclusionPattern

func (proc *Processor) SetExclusionPattern(pattern string) error

func (*Processor) ShowSummary

func (proc *Processor) ShowSummary()

func (*Processor) Unmatch

func (proc *Processor) Unmatch(files []string) error

type StatsCollector

type StatsCollector struct {
	NumFilesToProcess   int
	NumFramesToGenerate int
	NumFramesGenerated  int
	NumTotalComparisons int
	NumComparisonsMade  int
	NumCacheHits        int
	NumMatches          int
	NumFalsePositives   int

	QuietMode bool // don't show progress
	// contains filtered or unexported fields
}

func (*StatsCollector) EstimateCompletionETA

func (stats *StatsCollector) EstimateCompletionETA() (int, error)

func (*StatsCollector) IncNumComparisonsMade

func (stats *StatsCollector) IncNumComparisonsMade()

func (*StatsCollector) IncNumFilesGenerated

func (stats *StatsCollector) IncNumFilesGenerated()

func (*StatsCollector) ShowSummary

func (stats *StatsCollector) ShowSummary()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL