mirror of
https://github.com/rasbt/LLMs-from-scratch.git
synced 2025-12-24 13:42:08 +00:00
use utf-8 encoding in json
This commit is contained in:
parent
fa56c80402
commit
46fcde15d8
@ -48,10 +48,10 @@
|
||||
"name": "stdout",
|
||||
"output_type": "stream",
|
||||
"text": [
|
||||
"matplotlib version: 3.8.4\n",
|
||||
"tiktoken version: 0.6.0\n",
|
||||
"torch version: 2.2.2\n",
|
||||
"tqdm version: 4.66.2\n",
|
||||
"matplotlib version: 3.9.0\n",
|
||||
"tiktoken version: 0.7.0\n",
|
||||
"torch version: 2.3.1\n",
|
||||
"tqdm version: 4.66.4\n",
|
||||
"tensorflow version: 2.16.1\n"
|
||||
]
|
||||
}
|
||||
@ -146,7 +146,7 @@
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 3,
|
||||
"execution_count": 2,
|
||||
"id": "0G3axLw6kY1N",
|
||||
"metadata": {
|
||||
"colab": {
|
||||
@ -181,7 +181,7 @@
|
||||
" with open(file_path, \"r\", encoding=\"utf-8\") as file:\n",
|
||||
" text_data = file.read()\n",
|
||||
"\n",
|
||||
" with open(file_path, \"r\") as file:\n",
|
||||
" with open(file_path, \"r\", encoding=\"utf-8\") as file:\n",
|
||||
" data = json.load(file)\n",
|
||||
"\n",
|
||||
" return data\n",
|
||||
@ -209,7 +209,7 @@
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 4,
|
||||
"execution_count": 3,
|
||||
"id": "-LiuBMsHkzQV",
|
||||
"metadata": {
|
||||
"colab": {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user