3ca079a980
- 中文目录名改为英文:cDNA图像处理实例→examples,参考资料→references - web→app(Flask应用标准命名) - 输出目录平移到 data/output/simple/ 和 data/output/full/ - 输入图像统一到 data/input/ - 构建脚本移到 scripts/ - 源码文件改用 snake_case 命名 - 更新所有文件路径引用和文档
39 lines
1.1 KiB
Python
39 lines
1.1 KiB
Python
"""
|
|
PyInstaller打包脚本
|
|
运行: python scripts/build.py
|
|
输出: dist/cDNA_Analyzer.exe
|
|
"""
|
|
|
|
import PyInstaller.__main__
|
|
import os
|
|
|
|
PyInstaller.__main__.run([
|
|
'app/launcher.py',
|
|
'--name=cDNA_Analyzer',
|
|
'--onefile',
|
|
'--noconsole',
|
|
'--add-data', f'app/templates;templates',
|
|
'--add-data', f'app/static;static',
|
|
# 排除不相关的重量级包(环境里有torch/pandas等)
|
|
'--exclude-module', 'torch',
|
|
'--exclude-module', 'torchvision',
|
|
'--exclude-module', 'torchaudio',
|
|
'--exclude-module', 'pandas',
|
|
'--exclude-module', 'sklearn',
|
|
'--exclude-module', 'sqlalchemy',
|
|
'--exclude-module', 'pygame',
|
|
'--exclude-module', 'zmq',
|
|
'--exclude-module', 'IPython',
|
|
'--exclude-module', 'jedi',
|
|
'--exclude-module', 'numba',
|
|
'--exclude-module', 'llvmlite',
|
|
'--exclude-module', 'onnxruntime',
|
|
'--exclude-module', 'lxml',
|
|
'--exclude-module', 'cryptography',
|
|
'--exclude-module', 'bcrypt',
|
|
'--exclude-module', 'pygments',
|
|
'--clean',
|
|
'--noconfirm',
|
|
])
|
|
print('\n完成!exe 在 dist/cDNA_Analyzer.exe')
|