标准数据集需先按 data/README.md 自行下载;单机/多机脚本依赖 Slurm 的 sbatch,无 Slurm 环境要用 scripts/local_run.sh;Docker 方案需在包含 RandOpt/ 的上级目录构建镜像。
RandOpt
sunrainyg活跃维护围绕预训练权重做黑盒优化与神经进化,用 LoRA 集成多个任务专家,提升大模型后训练与推理表现。
Official Codebase for "Neural Thickets: Diverse Task Experts Are Dense Around Pretrained Weights" (ICML 2026 Spotlight)
pip install -r requirements.txtREADME 未说明具体显存或 GPU 型号要求;Docker 方案以 --gpus all 启动,说明需要 NVIDIA GPU 环境。
在预训练权重附近随机采样即可得到多样任务专家,RandOpt 帮你后训练与蒸馏
围绕预训练权重做黑盒优化与神经进化,用 LoRA 集成多个任务专家,提升大模型后训练与推理表现。
核心能力
- 在预训练权重邻域随机扰动采样,得到多样任务专家
- 支持单机、多机 Slurm 及本地无 Slurm 三种后训练模式
- 提供将 top-k 专家模型蒸馏为单一模型的流程
- 附带 baselines 复现脚本与自定义数据集指南
- iterative-randopt 分支支持 pip 安装并接入 verl 或 trl
容易踩的坑
暂无 release 数据(可能没有发版,或尚未同步)。
用户点评
登录用户的真实使用记录,可按版本和硬件筛选还没有人点评。第一个说出真实体验的人最有价值。
RandOpt
Neural Thickets: Diverse Task Experts Are Dense Around Pretrained Weights
Paper | Project Page | Openreview | Starting with a 1D Experiment:
News
- [2026-07] Iterative RandOpt is now on the
iterative-randoptbranch! Also support thepip install-able implementation that drops into existing verl or huggingface/trl setups.
Requirements
Option1: Python / Conda
(optional) conda activate your_env
pip install -r requirements.txt
Option2: Docker
From the directory containing RandOpt/:
| Step | Command |
|---|---|
| Build | docker build -f RandOpt/docker/Dockerfile_vllm -t randopt-vllm:latest . |
| Run | docker run -it --gpus all randopt-vllm:latest bash |
| Run (with data) | docker run -it --gpus all -v /path/to/RandOpt/data:/workspace/data randopt-vllm:latest bash |
Run RandOpt
Post-train on your own dataset
Please follow the instructions in CUSTOM_DATASET_GUIDE.md
Post-train on a standard dataset
First download the data here: data/README.md
Then, from the RandOpt directory:
| Mode | Command |
|---|---|
| Single node | sbatch scripts/single_node.sh |
| Multiple nodes | sbatch scripts/multiple_nodes.sh |
| Local (no Slurm) | bash scripts/local_run.sh |
Distill top-k models into a single model
Please follow the instructions in distillation/README.md.
Run Baselines
Please follow the instructions in baselines/README.md
Having questions?
Open an issue @ github.com/sunrainyg/RandOpt/issues.
Citation
@misc{gan2026neuralthickets,
title={Neural Thickets: Diverse Task Experts Are Dense Around Pretrained Weights},
author={Yulu Gan and Phillip Isola},
year={2026},
eprint={2603.12228},
archivePrefix={arXiv},
primaryClass={cs.LG},
url={https://arxiv.org/abs/2603.12228},
}