Skip to content
Open

2026 #206

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions lab1/PT_Part2_Music_Generation.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -652,6 +652,11 @@
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "GuGUJB0ZT_Uo"
},
"outputs": [],
"source": [
"### compute the loss on the predictions from the untrained model from earlier. ###\n",
"y.shape # (batch_size, sequence_length)\n",
Expand All @@ -663,12 +668,7 @@
"\n",
"print(f\"Prediction shape: {pred.shape} # (batch_size, sequence_length, vocab_size)\")\n",
"print(f\"scalar_loss: {example_batch_loss.mean().item()}\")"
],
"metadata": {
"id": "GuGUJB0ZT_Uo"
},
"execution_count": null,
"outputs": []
]
},
{
"cell_type": "markdown",
Expand Down Expand Up @@ -906,7 +906,7 @@
"\n",
" for i in tqdm(range(generation_length)):\n",
" '''TODO: evaluate the inputs and generate the next character predictions'''\n",
" predictions, hidden_state = model('''TODO''', '''TODO''', return_state=True) # TODO\n",
" predictions, state = model('''TODO''', '''TODO''', return_state=True) # TODO\n",
"\n",
" # Remove the batch dimension\n",
" predictions = predictions.squeeze(0)\n",
Expand Down
Loading