Skip to content

Instantly share code, notes, and snippets.

View zedom1's full-sized avatar
🎯
Focusing

Zedom zedom1

🎯
Focusing
View GitHub Profile
import tensorflow as tf
from numpy import *
from random import randint
max_length = 3
batch_size = 5
targets = array([[1 for _ in range(max_length)] for _ in range(batch_size)])
logits = array([[[randint(0,10)/10,randint(0,10)/10] for _ in range(max_length)] for _ in range(batch_size)])
sequence_length = array([randint(1,max_length) for _ in range(batch_size)])
import tensorflow as tf
from numpy import *
from random import randint
max_length = 2
batch_size = 3
label = array([[[0,0] for _ in range(max_length)] for _ in range(batch_size)])
for i in range(batch_size):
for j in range(max_length):