deepr.examples.movielens.metrics package

Submodules

deepr.examples.movielens.metrics.ndcg module

NDCG metrics.

class deepr.examples.movielens.metrics.ndcg.NDCGAtK(name, logits, targets, k, inputs=None)[source]

Bases: Metric

Normalized Discounted Cumulative Gain at K

name

Name of the metric

Type:

str

logits

Tensor with logits, shape = (batch, num_classes)

Type:

str

targets

Tensor with indices, shape = (batch, …, num_target)

Type:

str

k

Top k logits for recall

Type:

int

inputs

One-hot tensor of “masked” classes, shape = (batch, num_casses)

Type:

str, optional

deepr.examples.movielens.metrics.recall module

Recall metrics.

class deepr.examples.movielens.metrics.recall.RecallAtK(name, logits, targets, k, inputs=None)[source]

Bases: Metric

Recall at k.

name

Name of the metric

Type:

str

logits

Tensor with logits, shape = (batch, num_classes)

Type:

str

targets

Tensor with indices, shape = (batch, …, num_target)

Type:

str

k

Top k logits for recall

Type:

int

inputs

One-hot tensor of “masked” classes, shape = (batch, num_casses)

Type:

str, optional

Module contents