Skip to content

Commit aa7adf0

Browse files
Kaixhinsoumith
authored andcommitted
Remove unused math import
Closes pytorch#204
1 parent 9fe431e commit aa7adf0

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

time_sequence_prediction/generate_sine_wave.py

+5-4
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
1-
import math
21
import numpy as np
32
import torch
3+
4+
np.random.seed(2)
5+
46
T = 20
57
L = 1000
68
N = 100
7-
np.random.seed(2)
9+
810
x = np.empty((N, L), 'int64')
9-
x[:] = np.array(range(L)) + np.random.randint(-4*T, 4*T, N).reshape(N, 1)
11+
x[:] = np.array(range(L)) + np.random.randint(-4 * T, 4 * T, N).reshape(N, 1)
1012
data = np.sin(x / 1.0 / T).astype('float64')
1113
torch.save(data, open('traindata.pt', 'wb'))
12-

0 commit comments

Comments
 (0)