ltbio.ml.datasets.augmentation#
Overview#
Classes#
Helper class that provides a standard way to create an ABC using |
|
Randomly makes missing samples (* 0) with probability probability. |
|
Inverts the signal (* -1) with probability probability. |
|
Adds gaussian noise to the signal with amplitude magnitude. |
|
Multiplies the signal by a random value between minimum_magnitude and 1. |
|
Temporally shifts the signal by displacement * number of samples. |
|
Adds a sine curve to the signal with random frequency and amplitude magnitude. |
|
Adds square pulses to the signal with random frequency and amplitude magnitude. |
Contents#
- class ltbio.ml.datasets.augmentation.DatasetAugmentationTechnique(parameter)#
Bases:
digraph inheritancebe1a45af89 { bgcolor=transparent; rankdir=LR; size="8.0, 12.0"; "ABC" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Helper class that provides a standard way to create an ABC using"]; "DatasetAugmentationTechnique" [URL="#ltbio.ml.datasets.augmentation.DatasetAugmentationTechnique",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "ABC" -> "DatasetAugmentationTechnique" [arrowsize=0.5,style="setlinewidth(0.5)"]; }abc.ABCHelper class that provides a standard way to create an ABC using inheritance.
- class ltbio.ml.datasets.augmentation.Drop(probability)#
Bases:
digraph inheritancefbe730c446 { bgcolor=transparent; rankdir=LR; size="8.0, 12.0"; "ABC" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Helper class that provides a standard way to create an ABC using"]; "DatasetAugmentationTechnique" [URL="#ltbio.ml.datasets.augmentation.DatasetAugmentationTechnique",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "ABC" -> "DatasetAugmentationTechnique" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Drop" [URL="#ltbio.ml.datasets.augmentation.Drop",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Randomly makes missing samples (* 0) with probability `probability`."]; "DatasetAugmentationTechnique" -> "Drop" [arrowsize=0.5,style="setlinewidth(0.5)"]; }DatasetAugmentationTechniqueRandomly makes missing samples (* 0) with probability probability. Common values for probability are between [0, 0.4]. Values for probability must be between [0, 1].
- class ltbio.ml.datasets.augmentation.Flip(probability)#
Bases:
digraph inheritancebb72fb149e { bgcolor=transparent; rankdir=LR; size="8.0, 12.0"; "ABC" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Helper class that provides a standard way to create an ABC using"]; "DatasetAugmentationTechnique" [URL="#ltbio.ml.datasets.augmentation.DatasetAugmentationTechnique",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "ABC" -> "DatasetAugmentationTechnique" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Flip" [URL="#ltbio.ml.datasets.augmentation.Flip",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Inverts the signal (* -1) with probability `probability`."]; "DatasetAugmentationTechnique" -> "Flip" [arrowsize=0.5,style="setlinewidth(0.5)"]; }DatasetAugmentationTechniqueInverts the signal (* -1) with probability probability. Values for probability must be between [0, 1].
- class ltbio.ml.datasets.augmentation.Randomness(magnitude)#
Bases:
digraph inheritancee646477fa8 { bgcolor=transparent; rankdir=LR; size="8.0, 12.0"; "ABC" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Helper class that provides a standard way to create an ABC using"]; "DatasetAugmentationTechnique" [URL="#ltbio.ml.datasets.augmentation.DatasetAugmentationTechnique",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "ABC" -> "DatasetAugmentationTechnique" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Randomness" [URL="#ltbio.ml.datasets.augmentation.Randomness",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Adds gaussian noise to the signal with amplitude `magnitude`."]; "DatasetAugmentationTechnique" -> "Randomness" [arrowsize=0.5,style="setlinewidth(0.5)"]; }DatasetAugmentationTechniqueAdds gaussian noise to the signal with amplitude magnitude. Common values for magnitude are between [0, 0.02].
- class ltbio.ml.datasets.augmentation.Scale(magnitude)#
Bases:
digraph inheritance104f43884a { bgcolor=transparent; rankdir=LR; size="8.0, 12.0"; "ABC" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Helper class that provides a standard way to create an ABC using"]; "DatasetAugmentationTechnique" [URL="#ltbio.ml.datasets.augmentation.DatasetAugmentationTechnique",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "ABC" -> "DatasetAugmentationTechnique" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Scale" [URL="#ltbio.ml.datasets.augmentation.Scale",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Multiplies the signal by a random value between `minimum_magnitude` and 1."]; "DatasetAugmentationTechnique" -> "Scale" [arrowsize=0.5,style="setlinewidth(0.5)"]; }DatasetAugmentationTechniqueMultiplies the signal by a random value between minimum_magnitude and 1. Common values for minimum_magnitude are between [0.25, 1[.
- class ltbio.ml.datasets.augmentation.Shift(displacement)#
Bases:
digraph inheritancede76572aa4 { bgcolor=transparent; rankdir=LR; size="8.0, 12.0"; "ABC" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Helper class that provides a standard way to create an ABC using"]; "DatasetAugmentationTechnique" [URL="#ltbio.ml.datasets.augmentation.DatasetAugmentationTechnique",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "ABC" -> "DatasetAugmentationTechnique" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Shift" [URL="#ltbio.ml.datasets.augmentation.Shift",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Temporally shifts the signal by `displacement` * number of samples."]; "DatasetAugmentationTechnique" -> "Shift" [arrowsize=0.5,style="setlinewidth(0.5)"]; }DatasetAugmentationTechniqueTemporally shifts the signal by displacement * number of samples. Direction (left or right) is chosen with equal probability. Values for displacement must be between [0, 1].
- class ltbio.ml.datasets.augmentation.Sine(magnitude)#
Bases:
digraph inheritance5b9e39da64 { bgcolor=transparent; rankdir=LR; size="8.0, 12.0"; "ABC" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Helper class that provides a standard way to create an ABC using"]; "DatasetAugmentationTechnique" [URL="#ltbio.ml.datasets.augmentation.DatasetAugmentationTechnique",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "ABC" -> "DatasetAugmentationTechnique" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Sine" [URL="#ltbio.ml.datasets.augmentation.Sine",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Adds a sine curve to the signal with random frequency and amplitude `magnitude`."]; "DatasetAugmentationTechnique" -> "Sine" [arrowsize=0.5,style="setlinewidth(0.5)"]; }DatasetAugmentationTechniqueAdds a sine curve to the signal with random frequency and amplitude magnitude. Frequency is random between [0.001, 0.02]. Common values for magnitude are between [0, 1].
- class ltbio.ml.datasets.augmentation.SquarePulse(magnitude)#
Bases:
digraph inheritance1b8c3577dd { bgcolor=transparent; rankdir=LR; size="8.0, 12.0"; "ABC" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Helper class that provides a standard way to create an ABC using"]; "DatasetAugmentationTechnique" [URL="#ltbio.ml.datasets.augmentation.DatasetAugmentationTechnique",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "ABC" -> "DatasetAugmentationTechnique" [arrowsize=0.5,style="setlinewidth(0.5)"]; "SquarePulse" [URL="#ltbio.ml.datasets.augmentation.SquarePulse",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Adds square pulses to the signal with random frequency and amplitude `magnitude`."]; "DatasetAugmentationTechnique" -> "SquarePulse" [arrowsize=0.5,style="setlinewidth(0.5)"]; }DatasetAugmentationTechniqueAdds square pulses to the signal with random frequency and amplitude magnitude. Frequency is random between [0.001, 0.1]. Common values for magnitude are between [0, 0.02].