crested.utils.one_hot_encode_sequence#
- crested.utils.one_hot_encode_sequence(sequence, expand_dim=True)#
One hot encode a DNA sequence.
Will return a numpy array with shape (len(sequence), 4) if expand_dim is True, otherwise (4,). Alphabet is ACGT.