torchdms.data.BinaryMapDataset

class torchdms.data.BinaryMapDataset(samples, targets, original_df, wtseq, target_names, alphabet)[source]

Bases: torch.utils.data.dataset.Dataset

Binarymap dataset.

This class organizes the information from the input dataset into a wrapper containing all relevent attributes for training and evaluation.

We also store the original dataframe as it may contain important metadata (such as target variance), but drop redundant columns that are already attributes.

Methods

cat

feature_count

of_raw

register_datapipe_as_function

register_function

target_count

target_extrema

Return a (min, max) tuple for the value of each target.

Attributes

functions

wt_idxs

target_extrema()[source]

Return a (min, max) tuple for the value of each target.