Enable dedicated MMSeg full mmcv runtime
This commit is contained in:
31
README.md
31
README.md
@@ -27,8 +27,9 @@ Seg_Data_Server_Net/
|
||||
cd Seg_Data_Server_Net
|
||||
cp .env.example .env
|
||||
|
||||
# Backend. The deployment env is seg_smp so the API and task wrappers share
|
||||
# the same segmentation dependency stack.
|
||||
# Backend. The deployment env is seg_smp so the API and most task wrappers
|
||||
# share the same segmentation dependency stack. MMSeg jobs default to the
|
||||
# separate SEG_MMSEG_CONDA_ENV because full mmcv wheels must match torch/CUDA.
|
||||
conda run -n seg_smp uvicorn app.main:app --app-dir backend --host 0.0.0.0 --port 8010
|
||||
|
||||
# Frontend.
|
||||
@@ -57,12 +58,23 @@ artifact API, runs a mock job, checks SSE log streaming, and executes one
|
||||
legacy image/label overlay job on tiny generated PNGs. It also runs model
|
||||
family readiness checks: a SegModel/SMP forward pass, a YOLO segmentation
|
||||
prediction on a tiny image, MMSeg config parsing, and local MMSeg pretrained
|
||||
weight discovery.
|
||||
weight discovery. MMSeg full-model readiness is validated in
|
||||
`SEG_MMSEG_CONDA_ENV` by importing `mmcv._ext` and building a local MMSeg
|
||||
`EncoderDecoder` from the existing config tree.
|
||||
|
||||
Current `seg_smp` uses `mmcv-lite` because no `torch 2.6/cu124` full `mmcv`
|
||||
wheel is available on this machine and `nvcc` is not installed for source
|
||||
builds. The acceptance smoke reports MMSeg full model construction as a
|
||||
warning until a full `mmcv` build with `mmcv._ext` is installed.
|
||||
builds. A dedicated `seg_mmcv` environment is used for MMSeg tasks and has
|
||||
`torch 2.1.2+cu121`, `mmcv 2.1.0`, `mmsegmentation 1.2.2`, and NumPy 1.26.
|
||||
If rebuilding the environment, keep these versions aligned:
|
||||
|
||||
```bash
|
||||
conda create -n seg_mmcv python=3.10 -y
|
||||
conda run -n seg_mmcv python -m pip install -U pip
|
||||
conda run -n seg_mmcv python -m pip install torch==2.1.2 torchvision==0.16.2 --index-url https://download.pytorch.org/whl/cu121
|
||||
conda run -n seg_mmcv python -m pip install mmengine==0.10.7 mmsegmentation==1.2.2 'mmcv==2.1.0' -f https://download.openmmlab.com/mmcv/dist/cu121/torch2.1/index.html
|
||||
conda run -n seg_mmcv python -m pip install 'numpy<2' 'opencv-python<4.12' ftfy regex matplotlib pandas scikit-learn scipy seaborn tqdm tensorboard
|
||||
```
|
||||
|
||||
## Weight Sync
|
||||
|
||||
@@ -118,7 +130,8 @@ Run the local evaluation and validation agents before publishing changes:
|
||||
PYTHONPATH=backend conda run -n seg_smp python scripts/run_agents.py --build
|
||||
```
|
||||
|
||||
The validation agent checks catalog coverage, the new `seg_smp` env, GPU
|
||||
visibility, no-weight Git safety, backend tests, frontend build, and live
|
||||
backend/frontend endpoints when the services are running. With live validation
|
||||
enabled it also runs the lightweight acceptance smoke above.
|
||||
The validation agent checks catalog coverage, the `seg_smp` task env, the
|
||||
`seg_mmcv` MMSeg env, GPU visibility, no-weight Git safety, backend tests,
|
||||
frontend build, and live backend/frontend endpoints when the services are
|
||||
running. With live validation enabled it also runs the lightweight acceptance
|
||||
smoke above.
|
||||
|
||||
Reference in New Issue
Block a user