Shortcuts

BinariesToCategory

class torcheeg.transforms.BinariesToCategory[source][source]

Convert multiple binary labels into one multiclass label. Multiclass labels represent permutations of binary labels. Commonly used to combine two binary classification tasks into a single quad classification task.

from torcheeg import transforms

t = transforms.BinariesToCategory()
t(y=[0, 0])['y']
>>> 0
t(y=[0, 1])['y']
>>> 1
t(y=[1, 0])['y']
>>> 2
t(y=[1, 1])['y']
>>> 3
__call__(*args, y: List, **kwargs) int[source][source]
Parameters:

y (list) – list of binary labels.

Returns:

The converted multiclass label.

Return type:

int

Read the Docs v: latest
Versions
latest
stable
v1.1.1
v1.1.0
v1.0.11
v1.0.10
v1.0.9
v1.0.8.post1
v1.0.8
v1.0.7
v1.0.6
v1.0.4
v1.0.3
v1.0.2
v1.0.1
Downloads
On Read the Docs
Project Home
Builds

Free document hosting provided by Read the Docs.

Docs

Access comprehensive developer documentation for PyTorch

View Docs

Tutorials

Get in-depth tutorials for beginners and advanced developers

View Tutorials

Resources

Find development resources and get your questions answered

View Resources