【jupyter】文件路径的更改

使用过 jupyter notebook 环境的同行, 都体会过随机生成 .html 静态网页的过程, 虽然文档较小, 但是不堪反复使用积少成多。本文基于windows系统。

找到 runtime 目录

一般 jupyter 默认 runtime 在下述格式目录中

C:\Users\用户名\AppData\Roaming\jupyter\runtime

复制一套 .html, .json 文件 (注意编号一致) 到期望的目录 "D://path/to/your/custom/" 。

cmd 环境下的python

建立 .bat 文件

cmd 复制代码
@echo off
start "Jupyter Server" cmd /k jupyter notebook
start "" "file:///D:/path/to/your/custom/htmlfile.html" 

双击运行 .bat 文件

conda 环境下的 python

建立 .bat 文件

cmd 复制代码
@echo off
call D:\path\miniconda3\Scripts\activate.bat
start "Jupyter Server" cmd /k jupyter notebook
start "" "file:///D:/path/to/your/custom/htmlfile.html"

双击运行 .bat 文件

相关推荐
萌萌站起3 分钟前
Vscode 中 python模块的导入问题
ide·vscode·python
是小蟹呀^17 分钟前
【总结】提示词工程
python·llm·prompt·agent
YBAdvanceFu19 分钟前
从零构建智能体:深入理解 ReAct Plan Solve Reflection 三大经典范式
人工智能·python·机器学习·数据挖掘·多智能体·智能体
王夏奇36 分钟前
python中的__all__ 具体用法
java·前端·python
王夏奇40 分钟前
pycharm中3种不同类型的python文件
ide·python·pycharm
小陈的进阶之路1 小时前
Selenium 滑动 vs Appium 滑动
python·selenium·测试工具·appium
Mike_6661 小时前
txt_json和xml_json
xml·python·json
zyq99101_12 小时前
DFS算法实战:经典例题代码解析
python·算法·蓝桥杯·深度优先
数据知道2 小时前
claw-code 源码分析:从 TypeScript 心智到 Python/Rust——跨栈移植时类型、边界与错误模型怎么对齐?
python·ai·rust·typescript·claude code·claw code
hhh3u3u3u2 小时前
Visual C++ 6.0中文版安装包下载教程及win11安装教程
java·c语言·开发语言·c++·python·c#·vc-1