mirror of
https://github.com/rasbt/LLMs-from-scratch.git
synced 2025-11-01 10:20:00 +00:00
use spam / not spam labels
This commit is contained in:
parent
45f6e72f40
commit
4b4e1e1ad5
@ -2184,7 +2184,7 @@
|
||||
" predicted_label = torch.argmax(logits, dim=-1).item()\n",
|
||||
"\n",
|
||||
" # Return the classified result\n",
|
||||
" return \"Positive\" if predicted_label == 1 else \"Negative\""
|
||||
" return \"spam\" if predicted_label == 1 else \"not spam\""
|
||||
]
|
||||
},
|
||||
{
|
||||
@ -2211,7 +2211,7 @@
|
||||
"name": "stdout",
|
||||
"output_type": "stream",
|
||||
"text": [
|
||||
"Positive\n"
|
||||
"spam\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
@ -2242,7 +2242,7 @@
|
||||
"name": "stdout",
|
||||
"output_type": "stream",
|
||||
"text": [
|
||||
"Negative\n"
|
||||
"not spam\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
@ -2347,7 +2347,7 @@
|
||||
"name": "python",
|
||||
"nbconvert_exporter": "python",
|
||||
"pygments_lexer": "ipython3",
|
||||
"version": "3.10.12"
|
||||
"version": "3.11.4"
|
||||
}
|
||||
},
|
||||
"nbformat": 4,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user