jupyter notebook相关
- 
centos使用jupyter notebook 
 参考:https://zhuanlan.zhihu.com/p/589702309
 403 forbidden: https://blog.csdn.net/langyu1021/article/details/98482589
- 
导出pdf 
 参考:https://blog.csdn.net/sinat_32872729/article/details/132445344
- 
设置环境变量 
 参考:https://blog.csdn.net/adreammaker/article/details/118858854
 参考:https://stackoverflow.com/questions/37890898/how-to-set-env-variable-in-jupyter-notebook
- 
设置定制化kernal 
 4.1jupyter kernelspec list查看系统中的kernal配置文件
 4.2 进入到相关目录修改相关kernel.json文件
{"argv": [
 # 设置环境变量
  "env",
  "VAR1=value1",
  "VAR2=value2",
  # 设置运行python环境
  "/path/to/python",
  "-m",
  "ipykernel_launcher",
  "-f",
  "{connection_file}"
],
# 在jupyter 中显示名称
"display_name": "Python (myenv)",
# 语言
"language": "python"
}
- 创建新kernel
#1. 创建虚拟环境并激活
conda create --name my_new_kernel_env python=3.10
conda activate my_new_kernel_env
# 或者
python3 -m venv my_new_kernel_env
source my_new_kernel_env/bin/activate
#2. 安装依赖
pip install ipykernel
#3. 将环境添加到jupyter
python -m ipykernel install --user --name=my_new_kernel --display-name "Python (my_new_kernel)"
# 4. 验证
jupyter kernelspec list
- 删除kernel
 jupyter kernelspec uninstall my_new_kernel
 
                    
                 
                
            
         浙公网安备 33010602011771号
浙公网安备 33010602011771号