mirror of
https://github.com/jiaxiaojunQAQ/OmniSafeBench-MM.git
synced 2026-02-12 17:52:46 +00:00
99 lines
2.1 KiB
TOML
99 lines
2.1 KiB
TOML
[build-system]
|
||
requires = ["setuptools>=61.0", "wheel"]
|
||
build-backend = "setuptools.build_meta"
|
||
|
||
[project]
|
||
name = "OmniSafeBench-MM"
|
||
version = "0.1.0"
|
||
description = "Add your description here"
|
||
readme = "README.md"
|
||
requires-python = ">=3.10"
|
||
dependencies = [
|
||
"accelerate>=1.12.0",
|
||
"backoff>=2.2.1",
|
||
"decord>=0.6.0",
|
||
"diffusers>=0.35.2",
|
||
"einops>=0.8.1",
|
||
"iopath>=0.1.10",
|
||
"matplotlib>=3.10.7",
|
||
"nltk>=3.9.2",
|
||
"omegaconf>=2.3.0",
|
||
"openai>=2.9.0",
|
||
"opencv-python>=4.12.0.88",
|
||
"pandas>=2.3.3",
|
||
"peft==0.17.1",
|
||
"pillow>=12.0.0",
|
||
"protobuf>=6.33.2", # 移除了 pip>=25.3,这不是项目依赖
|
||
"pyyaml>=6.0.3",
|
||
"scikit-image>=0.25.2",
|
||
"scipy>=1.15.3",
|
||
"seaborn>=0.13.2",
|
||
"sentence-transformers",
|
||
"sentencepiece>=0.2.1",
|
||
"spacy>=3.8.11",
|
||
"textaugment>=2.0.0",
|
||
"textblob==0.15.3",
|
||
"timm>=1.0.22",
|
||
"torch==2.6.0+cu118",
|
||
"torchvision==0.21.0+cu118",
|
||
"tqdm>=4.67.1",
|
||
"transformers==4.45",
|
||
"visual-genome>=1.1.1",
|
||
"wandb>=0.23.1",
|
||
"webdataset>=1.0.2",
|
||
]
|
||
|
||
# 关键:包发现配置(解决 flat-layout 问题)
|
||
[tool.setuptools]
|
||
# 方式1:明确列出所有包(推荐)
|
||
packages = [
|
||
"core",
|
||
"models",
|
||
"config",
|
||
"assets",
|
||
"attacks",
|
||
"dataset",
|
||
"pipeline",
|
||
"defenses",
|
||
"evaluators",
|
||
"multimodalmodels",
|
||
"dataset_generate",
|
||
]
|
||
|
||
# 或方式2:使用 find 指令(如果上面的包名正确)
|
||
# [tool.setuptools.packages.find]
|
||
# where = ["."]
|
||
# include = [
|
||
# "core*",
|
||
# "models*",
|
||
# "config*",
|
||
# "assets*",
|
||
# "output*",
|
||
# "attacks*",
|
||
# "dataset*",
|
||
# "pipeline*",
|
||
# "defenses*",
|
||
# "evaluators*",
|
||
# "multimodalmodels*",
|
||
# "dataset_generate*",
|
||
# ]
|
||
# exclude = [
|
||
# "tests*",
|
||
# "docs*",
|
||
# "examples*",
|
||
# "build*",
|
||
# "dist*",
|
||
# "*.egg-info*",
|
||
# ]
|
||
|
||
[tool.pytest.ini_options]
|
||
testpaths = ["tests"]
|
||
|
||
[[tool.uv.index]]
|
||
name = "pytorch-cu118"
|
||
url = "https://download.pytorch.org/whl/cu118"
|
||
explicit = true
|
||
|
||
[tool.uv.sources]
|
||
torch = { index = "pytorch-cu118" }
|
||
torchvision = { index = "pytorch-cu118" } |