# 深度学习及动手实践 **Repository Path**: nablacfd/DiveIntoDeepLearning ## Basic Information - **Project Name**: 深度学习及动手实践 - **Description**: 动手学习深度学习!!! - **Primary Language**: Python - **License**: GPL-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 1 - **Forks**: 1 - **Created**: 2021-08-28 - **Last Updated**: 2024-09-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 深度学习及动手实践 #### Description 动手学习深度学习!!! 学习过程的主要参考书籍《动手学深度学习》及其相关配套资源。 #### 动手深度学习 + [PyTorch官方gitHub](https://github.com/pytorch) + [动手学习深度学习-电子书(中文版)](https://zh-v2.d2l.ai/d2l-zh-pytorch.pdf)+[电子书(英文版)](https://d2l.ai/index.html)+[李沐gitHub](https://github.com/d2l-ai)+[PyTorch实现](https://github.com/dsgiitr/d2l-pytorch)。书籍的第二版主页:[https://zh.d2l.ai/](https://links.jianshu.com/go?to=https%3A%2F%2Fzh.d2l.ai%2F) (代码实现基于mxnet, pytorch, tensorflow),相关的PDF版亦可在群文件夹中找到。另外书籍也在更新和fix typos等,最新的书籍可以从以下网址获得: >2023-03-15更新 ++ 英文版git地址:[https://github.com/d2l-ai/d2l-en](https://links.jianshu.com/go?to=https%3A%2F%2Fgithub.com%2Fd2l-ai%2Fd2l-en) ++ 中文版git地址:[https://github.com/d2l-ai/d2l-zh](https://links.jianshu.com/go?to=https%3A%2F%2Fgithub.com%2Fd2l-ai%2Fd2l-zh) ++ 相关的讨论论坛:[https://discuss.d2l.ai/](https://links.jianshu.com/go?to=https%3A%2F%2Fdiscuss.d2l.ai%2F) ++ 在线课程:[https://courses.d2l.ai/zh-v2/](https://links.jianshu.com/go?to=https%3A%2F%2Fcourses.d2l.ai%2Fzh-v2%2F) ++ 中文课件:[https://github.com/d2l-ai/berkeley-stat-157/tree/master/slides-zh](https://links.jianshu.com/go?to=https%3A%2F%2Fgithub.com%2Fd2l-ai%2Fberkeley-stat-157%2Ftree%2Fmaster%2Fslides-zh) ++ 书中代码pytorch实现:[https://github.com/ShusenTang/Dive-into-DL-PyTorch] + [各种著名DL-networks的pytorch实现](https://nn.labml.ai/) >2023-4-1更新 PyTorch的官方文档及两本新书: 0. **[PyTorch的官方文档](https://pytorch.org/docs/stable/index.html)** 1. **[Zero to Mastery Learn PyTorch for Deep Learning](https://www.learnpytorch.io/)**及其对应的[源码](https://github.com/mrdbourke/pytorch-deep-learning) 2. **[Deep Learning with PyTorch](https://livebook.manning.com/book/deep-learning-with-pytorch/chapter-1/)** 3. **[Microsoft Train - PyTorch Fundamental](https://learn.microsoft.com/en-us/training/paths/pytorch-fundamentals/)** 4. Another resource: [Deep Learning with PyTorch](https://machinelearningmastery.com/deep-learning-with-pytorch/) #### 0. Python及PyTorch环境的安装 在windows环境下,首先下载Miniconda3-py39_23.1.0-1-Windows-x86_64,然后安装。然后使用Anaconda Powershell Prompt依次执行如下命令配置环境: ```powershell #在CPU系统安装 conda --version #观察已安装的conda的版本号 conda update conda #创建虚拟的python3.9环境,配置CPU版pytorch conda create --name d2l python=3.9 -y conda activate d2l #激活上述创建的python环境 #安装pytorch等DL框架 pip install torch==1.12.0 torchvision==0.13.0 pip install d2l==0.17.6 pip install jupyter #安装jupyter #现在动手学习深度学习的源代码,解压后放置目标位置;也可以在QQ群中找到都d2l-zh.zip,解压即可使用 curl https://zh-v2.d2l.ai/d2l-zh-2.0.0.zip -o d2l-zh.zip cd d2l-zh #在目标位置进入d2l目录 conda deactivate d2l #安装GPU版本 nvidia-smi.exe #观察系统中已安装的CUDA版本号,我的机器安装了CUDA version 12.0 conda create --name d2l-gpu python=3.9 -y conda activate d2l-gpu #但是pytorch的官网,并没有cuda-12.0对应版本,选择了一个最接近的小版本cu116 pip install torch==1.12.0+cu116 torchvision==0.13.0+cu116 torchaudio==0.12.0 --extra-index-url https://download.pytorch.org/whl/cu116 #后续和CPU版本是一样的 pip install d2l==0.17.6 pip install jupyter #安装jupyter #现在动手学习深度学习的源代码,解压后放置目标位置 curl https://zh-v2.d2l.ai/d2l-zh-2.0.0.zip -o d2l-zh.zip cd d2l-zh #在目标位置进入d2l目录 ``` ``` >conda info >conda info --env # conda info -e >conda list #列出所有安装的包信息 ``` ``` torch.cuda.is_available() torch.cuda.device_count() torch.cuda.list_gpu_processors() torch.cuda.get_device_name() # get_device_properties() or get_device_capability() ``` #### A.数据集的制作 + [制作自己数据的数据集-官方练习0-张量](https://zhuanlan.zhihu.com/p/374101286) + [制作自己数据的数据集-官方练习1-读取官方数据集](https://zhuanlan.zhihu.com/p/373976907) + [制作自己数据的数据集-官方练习2-派生自己的数据集](https://zhuanlan.zhihu.com/p/374116297) + [制作自己数据的数据集-官方练习3-数据转换](https://zhuanlan.zhihu.com/p/374188672) ### 学习进度安排 #### Week 1 + 完成第一章的学习。 #### Week2 2023-03-20 + 本周任务:第二章2.1-2.4节(不包括2.4节) #### Week3 2023-03-27 + 本周任务:完成第二章的全部内容,并且动手练习第二章的代码。 #### Week4 2023-04-02 本周任务(相对前两周,本周任务略多,请各位合理安排时间): + 熟悉官方文档,在其官方网址到处逛逛,浏览性查看其官方文档和帮助,看看里面都有什么。*这才是第一首资料*。 + 理解TENSOR(https://pytorch.org/tutorials/beginner/basics/tensorqs_tutorial.html) + 浏览TENSOR的所有操作(https://pytorch.org/docs/stable/torch.html#) + 完成《Deep Learning with PyTorch》第一和三章的阅读和学习,并对执行相应代码,生成对应的jupyter notebook文件。 + 第一章可以粗读,理解基本概况就。其网址链接如下:https://livebook.manning.com/book/deep-learning-with-pytorch/chapter-1/1 + 第三章应该适当精度,理解tensor(张量)和其基本操作。其网址链接如下:https://livebook.manning.com/book/deep-learning-with-pytorch/chapter-3/ + 完成《动手学深度学习》第三章内容的学习,及相应代码的重现。 相关的Python基础 + [Scipy Lecture Notes ](http://scipy-lectures.org/) #### Week5 复习(这些都是前几周学过的知识,大家可以看看这些视频,相对比较简单):相关视频P1-P40,网址为:[2023首发-深度学习PyTorch实战计算机视觉实战](https://www.bilibili.com/video/BV1T54y1c7pP/?vd_source=da0b9d6d2e578563d89dac2c7764880f)