本地访问autodl的jupyter notebook

建立环境并安装jupyter

conda create --name medkg python=3.10

source activate medkg

pip install jupyter

安装完成后,输入jupyter notebook --generate-config

输入ipython,进入python

In [2]: from jupyter_server.auth import passwd

In [3]: passwd(algorithm='sha1')

返回

记住密码,并输入exit();退出

编辑刚才的config文件 vim /root/.jupyter/jupyter_notebook_config.py

在最末尾插入

c.ServerApp.ip = '0.0.0.0'

c.ServerApp.password = ''#填写刚才生成出来的那个密码字符串

c.ServerApp.open_browser = False

c.ServerApp.port = 6006

c.ServerApp.allow_remote_access = True

输入!wq,回车,保存,

返回原来的控制台,重新输入jupyter notebook --allow-root

同时打开

下载autodl 的客户端,输入登录指令和密码,

点击最下面的访问地址,会弹出一个让你输入密码的页面,输入当时你本身设置的密码,不是sha1密码,即可访问。小记一下做备忘。

参考文献

链接: 1

链接: 2

相关推荐
开开心心就好16 小时前
图片格式转换工具,右键菜单一键转换简化
linux·运维·服务器·python·django·pdf·1024程序员节
骥龙16 小时前
1.2下、工欲善其事:物联网安全研究环境搭建指南
python·物联网·安全
Lxinccode17 小时前
BUG(20) : response.text耗时很久, linux耗时十几秒, Windows耗时零点几秒
python·bug·requests·response.text·response.text慢
智航GIS17 小时前
11.2 Matplotlib 数据可视化教程
python·信息可视化·matplotlib
技术净胜17 小时前
Python 操作 Cookie 完全指南,爬虫与 Web 开发实战
前端·爬虫·python
海棠AI实验室17 小时前
第六章 日志体系:logging 让排错效率翻倍
python·logging
laufing17 小时前
flask_restx 创建restful api
python·flask·restful
海棠AI实验室17 小时前
第七章 断点调试:VSCode 调试全流程(含常见坑)
ide·vscode·编辑器
毕设源码-郭学长18 小时前
【开题答辩全过程】以 基于python电商商城系统为例,包含答辩的问题和答案
开发语言·python