diff options
Diffstat (limited to 'model.py')
| -rw-r--r-- | model.py | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -339,11 +339,15 @@ class PrimedGenerator(Runner): def _noise(x): for i in range(n_samples): + if (i % 1000) == 0: + print("{}...".format(i)) x[:, i] = int(random.triangular(q_min, q_max)) return x def _sin(x): primer_freq = float(prime_param_a) for i in range(n_samples): + if (i % 1000) == 0: + print("{}...".format(i)) x[:, i] = int((math.sin(i/44100 * primer_freq) + 1) / 2 * (q_max - q_min) + q_min) return x @@ -353,10 +357,14 @@ class PrimedGenerator(Runner): 'sin': _sin, } + print "BUILDING SEQUENCES" + sequences = sequence_lookup.get(primer, 'zero')(sequences) # out_sequences = sequence_lookup.get(primer, 'zero')(out_sequences) out_sequences[:, :self.model.lookback] = sequences[:, :self.model.lookback] + print "BUILT...." + # here we are generating the subsequence each time, # but maybe we want to generate the subsequence bottom_frame_size length # and then draw from that, although this will really emphasize the recursion @@ -373,6 +381,8 @@ class PrimedGenerator(Runner): return tmp_sub_sequence + print "ENTERING LOOP...." + for i in range(self.model.lookback, self.model.lookback + seq_len): if (i % 1000) == 0: print("{}...".format(i)) |
