rank

package
v1.1.5 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DistCountRanker

type DistCountRanker struct {
}

func NewDistCountRanker

func NewDistCountRanker() *DistCountRanker

func (*DistCountRanker) Rank

func (r *DistCountRanker) Rank(productImages []search.ProductImage) []Product

type FirstImageRanker

type FirstImageRanker struct {
}

FirstImageRanker implements Ranker interface{}

func NewFirstImageRanker

func NewFirstImageRanker() *FirstImageRanker

NewFirstImageRanker returns a new FirstImageRanker

func (*FirstImageRanker) Rank

func (r *FirstImageRanker) Rank(productImages []search.ProductImage) []Product

Rank implements Ranker interface{}

type Product

type Product struct {
	Id    string
	Score float32
}

type Ranker

type Ranker interface {
	Rank(productImages []search.ProductImage) []Product
}

Jump to

Keyboard shortcuts

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