add learn jittor in 60 min

This commit is contained in:
Dun Liang 2021-07-12 01:21:19 +08:00
parent 304d5034fd
commit 7ff46370e3
7 changed files with 2930 additions and 1 deletions

View File

@ -9,7 +9,7 @@
# file 'LICENSE.txt', which is part of this source code package.
# ***************************************************************
__version__ = '1.2.3.60'
__version__ = '1.2.3.61'
from jittor_utils import lock
with lock.lock_scope():
ori_int = int

View File

@ -0,0 +1,11 @@
# 计图零基础入门教程60分钟
```
git clone https://github.com/Jittor/LearnJittorBasicIn60Min.git
cd LearnJittorBasicIn60Min
jupyter notebook
```
在线浏览地址:<https://nbviewer.jupyter.org/github/Jittor/LearnJittorBasicIn60Min/tree/master/>
特别感谢教程作者llt

Binary file not shown.

After

Width:  |  Height:  |  Size: 237 KiB

View File

@ -0,0 +1,138 @@
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# 计图入门教程 0 --- 介绍与安装"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"\n",
"**计图 (Jittor)** 是一个以 Python 为前端语言的深度学习框架,它 \n",
"* 效率高:可作为 NumPyPyTorch 的替代品,可以使用 GPU 等其他加速器进行高效的数据运算。除此之外,计图还拥有多个创新点,旨在大幅提升其运算效率;\n",
"* 易使用:是一个用于实现神经网络的自动微分库,并集成了大量有关深度学习的函数库,方便您快速开展开发任务。\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"\n",
"**通过本教程,您将**\n",
"* 学习并理解计图中基本类型的一般操作;\n",
"* 了解神经网络的一些基本概念,并学会如何利用计图进行神经网络的训练;\n",
"* 解决一个机器学习的经典实战问题。\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"**本教程的适用群体:** \n",
"我们的目标是,只要您会 Python 编程,即可通过本教程学习并掌握如何使用计图进行深度学习的开发。不用担心,本教程几乎对所有的关键代码都加以注释说明。只要您耐心跟着本教程一步步学习,便一定能有所斩获。"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"现在,请您开启计图快速入门之旅。"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"\n",
"## 安装\n",
"\n",
"\n",
"Jittor框架对环境要求如下:\n",
"\n",
"\n",
"* 操作系统: **Ubuntu** >= 16.04 或 **Windows Subsystem of LinuxWSL**\n",
"* Python版本 >= 3.7\n",
"* C++编译器 (需要下列至少一个)\n",
" - g++ >=5.4.0\n",
" - clang >=8.0\n",
"* GPU 编译器可选nvcc >=10.0\n",
"* GPU 加速库可选cudnn-dev (cudnn开发版, 推荐使用tar安装方法[参考链接](https://docs.nvidia.com/deeplearning/cudnn/install-guide/index.html#installlinux-tar))\n",
"\n",
"如果您不希望手动配置环境,我们推荐使用 Docker 进行安装。\n",
"除此之外,您还可以使用 pip 安装和手动安装。\n",
"\n",
"注意目前Jittor通过WSL的方式在Windows操作系统上运行WSL的安装方法请参考[微软官网](https://docs.microsoft.com/en-us/windows/wsl/install-win10)WSL版本目前尚不支持CUDA。\n",
"\n",
"Jittor 提供了三种安装方法dockerpip和手动安装\n",
"\n",
"\n",
"\n",
"## Docker 安装\n",
"\n",
"我们提供了Docker安装方式免去您配置环境Docker安装方法如下\n",
"\n",
"\n",
"```\n",
"# CPU only(Linux)\n",
"docker run -it --network host jittor/jittor\n",
"# CPU and CUDA(Linux)\n",
"docker run -it --network host --gpus all jittor/jittor-cuda\n",
"# CPU only(Mac and Windows)\n",
"docker run -it -p 8888:8888 jittor/jittor\n",
"# Upgrade jittor docker image\n",
"docker pull jittor/jittor\n",
"docker pull jittor/jittor-cuda\n",
"```\n",
"\n",
"关于Docker安装的详细教程可以参考[Windows/Mac/Linux通过Docker安装计图](https://cg.cs.tsinghua.edu.cn/jittor/tutorial/2020-5-15-00-00-docker/)\n",
"\n",
"## Pip 安装\n",
"\n",
"\n",
"如果您没有准备好环境或者使用的不是Ubuntu操作系统 推荐使用**docker安装** 如果您已经装好编译器和对应版本的Python,我们强烈推荐您使用这种方法\n",
"(如果无法访问github, 可以通过jittor主页下载):\n",
"\n",
"```bash\n",
"sudo apt install python3.7-dev libomp-dev\n",
"python3.7 -m pip install jittor\n",
"# or install from github(latest version)\n",
"# python3.7 -m pip install git+https://github.com/Jittor/jittor.git\n",
"python3.7 -m jittor.test.test_example\n",
"\n",
"# Upgrade jittor from pip\n",
"python3.7 -m pip install jittor -U\n",
"# Upgrade jittor from github\n",
"python3.7 -m pip install git+https://github.com/Jittor/jittor.git -U\n",
"```\n",
"\n",
"如果测试运行通过,恭喜你已经安装完成.\n",
"jittor会自动在路径中寻找合适的编译器, 如果您希望手动指定编译器, 请使用环境变量 `cc_path` 和 `nvcc_path`(可选).\n"
]
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.5"
}
},
"nbformat": 4,
"nbformat_minor": 4
}

File diff suppressed because one or more lines are too long