jupyter/README_CN.md
ben0i0d 5053e35c41
All checks were successful
Flow / Base (push) Successful in 5s
Flow / SCIPY (push) Successful in 5s
Flow / PYAI_C (push) Successful in 7s
Flow / SCRPY (push) Successful in 7s
Flow / SQL (push) Successful in 8s
Flow / PYFLINK (push) Successful in 10s
Flow / AGDA (push) Successful in 10s
Flow / ANSIBLE (push) Successful in 8s
Flow / C (push) Successful in 11s
Flow / CADABRA2 (push) Successful in 10s
Flow / CHAPEL (push) Successful in 9s
Flow / CPP (push) Successful in 9s
Flow / DYALOG (push) Successful in 8s
Flow / FORTRAN (push) Successful in 9s
Flow / GO (push) Successful in 9s
Flow / HASKELL (push) Successful in 10s
Flow / JAVA (push) Successful in 9s
Flow / JS (push) Successful in 10s
Flow / JULIA (push) Successful in 9s
Flow / KOTLIN (push) Successful in 11s
Flow / LUA (push) Successful in 10s
Flow / R (push) Successful in 11s
Flow / NOVNC (push) Successful in 9s
Flow / OCTAVE (push) Successful in 12s
Flow / SAGEMATH (push) Successful in 13s
Flow / MAPLE (push) Successful in 9s
Flow / MMA (push) Successful in 11s
Flow / MATLAB_MINIMAL (push) Successful in 9s
Flow / PYQT6 (push) Successful in 9s
Flow / SCILAB (push) Successful in 22s
Flow / MATLAB_MCM (push) Successful in 6s
Flow / PYSPARK (push) Successful in 1m33s
Flow / Push (push) Successful in 31s
Push_ghcr / Push (push) Successful in 1h2m14s
update
2025-03-11 00:44:01 +08:00

164 lines
5.9 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# jupyter-image-stacks
## 通用的Jupyterlab镜像组
English | [中文](README_CN.md)
**为中国用户的文档**
**ghcr.io: https://github.com/eoeair/jupyter/pkgs/container/jupyter**
**Our Gitea: https://eoelab.org:1027/eoeair/jupyter**
### 如何使用
**Docker**
* 没有数据持久化地使用:`docker run -d -p 8888:8888 ghcr.io/eoeair/jupyter:<tag>`
* 提供数据持久化地使用:`docker run -d -p 8888:8888 -v "${PWD}":/home/jovyan ghcr.io/eoeair/jupyter:<tag>`
**Jupyterhub on K8S**
在singleuser内的profile指定镜像
```
- description: 提供Python的科学计算环境提供了丰富的数值计算、优化、信号处理、统计分析等功能用于科学研究和工程应用。
display_name: Scipy
kubespawner_override:
image: ghcr.io/eoeair/jupyter:scipy
```
**Jupyterhub on Docker**
```
c.DockerSpawner.allowed_images = {
'Scipy': 'ghcr.io/eoeair/jupyter:scipy'
}
```
### 全局说明
1. 如果自行构建或派生替换dockerfile中的基础镜像为dockerhub上的镜像
2. 对于例如MathematicaMATLAB等商业软件我们只提供打包具体激活方式及可能带来的后果由用户承担
3. 以下代码适用于解决matplotlib绘图缺失中文字体(使用前需要先安装wqy-zenhei字体)
```
from matplotlib.font_manager import FontProperties
# 设置中文字体路径
zh_font = FontProperties(fname="/usr/share/fonts/truetype/wqy/wqy-zenhei.ttc")
# 将中文字体设置为默认字体
plt.rcParams["font.family"] = zh_font.get_name()
```
### 需要额外说明的镜像
* Base基础镜像包含jupyterhubjupyterlab相当于jupyter官方的minimal-notebook镜像
* 说明
1. 上游已经切换到`debian:trixie-slim`
2. 添加了sudo的无密码使用在安全要求较高的场景中不要允许特权提升
3. 提供软件包:.zip文件解压
* Python支持Python。
* Scipy提供Python的科学计算环境
* Scrpy: 提供Python的网页采取环境适用于数据挖掘、网络爬虫
* pyspark: 提供基于Python的Spark编程接口
* pyflink: 提供基于Python的Flink编程接口
* pyaiWith GPU提供Pytorch。
* Julia支持Julia
* 说明:
1. Julia镜像中的环境变量`JULIA_NUM_THREADS`请在启动时根据理想的并发线程数进行配置默认为8
* Maple: 一个数学软件,透过智能文件界面提供强大数学引擎,可以轻松分析、探索、可视化和求解数学问题
* 说明
1.`license.dat libmaple.so`上传至主目录,每一次启动环境时,运行`sudo cp license.dat /opt/maple/license && sudo cp libmaple.so /opt/maple/bin.X86_64_LINUX/`完成激活再使用
* Mathematica:一个科学计算软件,在数据分析、数学计算等领域提供了强大方便的使用功能。
* 说明
1. 每一次启动环境时,运行`WolframKernel`完成手动激活,激活码查看`https://paran3xus.github.io/2024/08/24/mathematica-14.1-crack/`,如果多次激活不成功,请运行`rm /home/jovyan/.Mathematica/Licensing/mathpass`删除之前的许可记录
2. 如果你有账户使用WEB验证/在线验证
3. 该镜像存在问题, kernel 卡在 connecting.
* MATLAB一种支持数据分析、算法开发和建模的编程和数值计算平台。
* 说明
1.`license.lic libmwlmgrimpl.so`上传至主目录,每一次启动环境时,运行`sudo cp license.lic /opt/matlab/r2023b/licenses/ && sudo cp libmwlmgrimpl.so /opt/matlab/r2023b/bin/glnxa64/matlab_startup_plugins/lmgrimpl/`完成激活再使用
2. 如果你有账户使用WEB验证/在线验证
* minimal:仅仅包含`Product:MATLAB`
* mcm:包含数学建模所需要的工具箱
### 插件清单
**全局**
* jupyterlab-language-pack-zh-CN:对中文的支持
* jupyterlab-lsp用于自动补全、参数建议、函数文档查询、跳转定义
* jupyterlab-execute-time: 用于显示代码执行时间
* jedi-language-server: Python 语言服务器
**局部**
* R: r-languageserver: R 语言服务器
* Julia: julia-language-server: Julia 语言服务器
### 镜像依赖关系
```mermaid
graph LR
Python-->P{PROGRAMLANG}
P-->PA(R)
P-->PB(Julia)
P-->PC(C)
P-->PD(Cpp)
P-->PE(Ansible)
P-->PF(Chapel)
P-->PG(Dyalog)
P-->PH(Fortran)
P-->PI(Go)
P-->PJ(Haskell)
P-->PK(Java)
P-->PL(Js)
P-->PM(Kotlin)
P-->PN(Lua)
Python-->G{GUI}-->GA(Novnc)-->GAA(Pyqt6)
Python-->S{Science-compute}-->SA(Scipy)
S-->SB(Pyai)
Python-->B{BigData}-->BA(pyspark)
B-->BB(pyflink)
B-->BC(Scrpy)
B-->BD(Sql)
Python-->M{MATH-TOOL}-->MA(Octave)
M-->MB(Maple)
M-->MC(Sagemath)
M-->MD(MATLAB-minimal)-->MDA(Matlab-mcm)
M-->ME(Mathematica)
M-->MF(Scilab)
```
## 上游
**软件包版本**
* cuda 12.4.0
* Python 3.11
* Julia latest
* spark 3.5.5
* flink 1.20.0
* jupyterlab 4
* Matlab R2023b
* Mathematica 14.1
* Maple 2024.2
**默认镜像源**
* pip bfsuhttps://mirrors.bfsu.edu.cn/help/pypi/
* apt ustchttps://mirrors.ustc.edu.cn/help/debian.html
* apache ustc: https://mirrors.ustc.edu.cn/apache/
* julia-pkg mirrorz: https://mirrors.cernet.edu.cn/julia
* CRAN ustchttps://mirrors.ustc.edu.cn/CRAN/
***现在你可以通过ARG选择你需要的镜像站点***
### 项目上游
jupyter团队项目 https://github.com/jupyter/docker-stacks
**但是我们与上游差别较大包括源软件包本地化与扩展等因此如果您从本项目派生遇到问题请不要到jupyter团队提问这会加大他们的工作量**
### kernel
* Pythonhttps://ipython.org/
* Julia: https://github.com/JuliaLang/IJulia.jl
* R: http://irkernel.github.io/
* Octave: https://github.com/Calysto/octave_kernel
* MATLAB: https://github.com/mathworks/jupyter-matlab-proxy
* MMA: https://github.com/WolframResearch/WolframLanguageForJupyter
## 必要的版权说明
对于派生自其他团队的代码,我们在文件头添加了原版版权声明,我们保留并且支持其他开发团队版权