news 2026/3/24 18:00:29

AI_report

作者头像

张小明

前端开发工程师

1.2k 24
文章封面图
AI_report

安装基础依赖包

pip3 install pydub pip3 install loguru pip3 install pandas

安装docx依赖

① 先用 apt 装系统 lxml(通常是有的)

sudo apt update
sudo apt install -y python3-lxml

② 再用 pip 装 python-docx(不装依赖)

pip3 install python-docx --no-deps

👉 因为:

  • python-docx本身是纯 Python

  • 依赖只有lxml

  • 我们已经提前解决了lxml

安装LibreOffice

如果这台 sophon 机器允许装软件,直接:

sudo apt install -y libreoffice

或者精简一点(只要转 PDF):

sudo apt install -y libreoffice-writer

验证:

which libreoffice libreoffice --version

正常安装特别慢,建议换国内 ARM 镜像源(立刻提速)

ports.ubuntu.com在国内基本必慢
必须换成清华 / 阿里 / 中科大 ARM ports 镜像

⭐ 推荐:清华 TUNA(ARM 支持最好)

1️⃣ 备份原 sources.list

sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak

2️⃣ 替换为清华 ARM ports 源

sudo nano /etc/apt/sources.list

全部替换为:

deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ focal main universe multiverse restricted deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ focal-updates main universe multiverse restricted deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ focal-security main universe multiverse restricted

保存退出。


3️⃣ 更新 + 继续安装(断点续下)

sudo apt clean sudo apt update sudo apt install -y libreoffice-writer

⚠️强烈建议用libreoffice-writer,别装全家桶 libreoffice

  • 转 docx → pdf只需要 writer

  • 体积小很多(但还是不小)

👉 一般会从kB/s → MB/s

安装字体

解压目录下的字体

unzip SourceHanSansSC.zip

sudo mkdir -p /usr/share/fonts/source-han-sans sudo cp SourceHanSansSC/*.otf /usr/share/fonts/source-han-sans/

3️⃣ 刷新字体缓存(非常关键)

sudo fc-cache -fv

4️⃣ 验证系统是否识别成功

fc-list | grep "Source Han Sans"

版权声明: 本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若内容造成侵权/违法违规/事实不符,请联系邮箱:809451989@qq.com进行投诉反馈,一经查实,立即删除!
网站建设 2026/3/19 5:59:30

好写作AI:当AI开始“抓”AI,这场学术“猫鼠游戏”该停战了

你的论文AI润色后行云流水,查重率1%,正窃喜时,导师发来邮件:“系统显示AI生成概率92%,来我办公室聊聊?” —— 欢迎来到学术原创性的“量子纠缠”战场。 深夜,你看着“AI文本检测工具”将你的论…

作者头像 李华