graykode / graykode/nlp-tutorial
About make_batch of NNLM
Aperta
- Lingua principale
- Jupyter Notebook
- Stelle
- 14.9k
- Fork
- 3.9k
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
```python
input = [word_dict[n] for n in word[:-1]] # create (1~n-1) as input
target = [word_dict[word[-1]]]
```
it constraints the length of input and n_step. I think the following example is even better
```python
for i in range(len(words) - window_size + 1):`
` x_train.append(words[i: i + window_size - 1])`
`y_train.append(words[i + window_size - 1])
```
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.