Esempio n. 1
0
def assert_no_time(X):
    if X.ndim == 2:
        return X
    if X.ndim != 3:
        raise ValueError('ndim must be 2 or 3, but it is %i' % X.ndim)
    return wild_reshape(X, (-1, X.shape[2]))
Esempio n. 2
0
def assert_no_time(X):
    if X.ndim == 2:
        return X
    if X.ndim != 3:
        raise ValueError('ndim must be 2 or 3, but it is %i' % X.ndim)
    return wild_reshape(X, (-1, X.shape[2]))
Esempio n. 3
0
def recover_time(X, time_steps):
    return wild_reshape(X, (time_steps, -1, X.shape[1]))
Esempio n. 4
0
def recover_time(X, time_steps):
    return wild_reshape(X, (time_steps, -1, X.shape[1]))