Debug a training loop where epochs 2 and 3 do nothing
Interview insights are lockedSee how often this is asked and which companies asked it with Buncho Pro.import json
def load_examples(path):
with open(path) as f:
for line in f:
yield json.loads(line)
examples = load_examples("train.jsonl")
print("examples:", len(examples))
for epoch in range(3):
total = 0
for ex examples:
total += train_step(ex)
(epoch, total)