Skip to content

Commit

Permalink
fix df cases (#58)
Browse files Browse the repository at this point in the history
  • Loading branch information
luweizheng authored Jul 9, 2024
1 parent c43d7ce commit 376cab0
Show file tree
Hide file tree
Showing 4 changed files with 1,387 additions and 82 deletions.
1 change: 1 addition & 0 deletions _toc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ subtrees:
- file: ch-dask-dataframe/indexing
- file: ch-dask-dataframe/map-partitions
- file: ch-dask-dataframe/shuffle
- file: ch-dask-dataframe/dask-case-study
- file: ch-dask-ml/index
entries:
- file: ch-dask-ml/preprocessing
Expand Down

Large diffs are not rendered by default.

15 changes: 7 additions & 8 deletions ch-ray-data/modin.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -318,8 +318,9 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"## 案例:纽约市出租车数据集\n",
"纽约市出租车数据集记录了黄色出租车的详细行程信息,包括上车和下车时间、乘客数量、行程距离及费用等。这些数据通常用来分析出租车的使用情况、交通模式、乘客行为等,我们将使用 Modin 进行数据分析实战案例。"
"## 案例:纽约市出租车数据分析\n",
"\n",
"我们将使用 Modin 对出租车数据进行数据分析。"
]
},
{
Expand All @@ -330,8 +331,6 @@
"source": [
"import os\n",
"\n",
"new_directory = \"/home/u2022201752/scale-py-zh\"\n",
"os.chdir(new_directory)\n",
"os.environ[\"MODIN_ENGINE\"] = \"dask\"\n",
"\n",
"import modin.config as modin_cfg\n",
Expand All @@ -348,7 +347,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"我们先读取数据。我们可以使用`read_parquet_glob()`与通配符`*`直接读取多个Parquet文件,在这里我们仅使用`read_parquet()`。"
"我们先读取数据。我们可以使用 `read_parquet_glob()` 与通配符 `*` 直接读取多个 Parquet 文件,在这里我们仅使用 `read_parquet()`。"
]
},
{
Expand Down Expand Up @@ -582,7 +581,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"接下来我们进行数据的条件筛选并使用`groupby()`切分数据。"
"接下来我们进行数据的条件筛选并使用 `groupby()` 切分数据。"
]
},
{
Expand Down Expand Up @@ -658,7 +657,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"我们再使用`apply()`对数据进行操作,以及使用`pivot_table()`创建数据透视表。"
"我们再使用 `apply()` 对数据进行操作,以及使用 `pivot_table()` 创建数据透视表。"
]
},
{
Expand Down Expand Up @@ -762,7 +761,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.9"
"version": "3.11.8"
}
},
"nbformat": 4,
Expand Down
2 changes: 1 addition & 1 deletion utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def nyc_taxi():

@data_path_decorator
def nyc_flights():
return ["https://dp.godaai.org/nyc-flights.zip"]
return ["https://scale-py.godaai.org/nyc-flights.zip"]


@data_path_decorator
Expand Down

0 comments on commit 376cab0

Please sign in to comment.