executing-plans
executing-plans
Use when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available
legacy-modelsOperate the repository's legacy TensorRT Caffe demos: build GoogLeNet classification and the three-stage MTCNN face detector, compile the pytrt Cython bridge, validate model/label assets, and diagnose version-bound runtime failures.
Independent GitHub snapshot · Automated classification · Original documentation governs
Use this sub-skill when a task concerns the googlenet/ or mtcnn/ demos,
pytrt.pyx/pytrt.pxd, trt_googlenet*.py, trt_mtcnn.py, or
utils/mtcnn.py. It describes the repository snapshot's legacy Caffe and
TensorRT execution path. It does not install packages, download models,
or ship generated engines, shared libraries, Caffe weights, or installers.
The normal working directory for every command below is the repository root.
Run python3 scripts/validate-legacy-model-assets.py --repo-root . before a
build. Read references/workflows.md for the ordered
build/inference procedure, api-reference.md for tensor and
threshold contracts, and compatibility.md before selecting
a TensorRT version.
pytrt extension are required for these two
demos. A CPU-only Python check cannot prove inference readiness.--help is conditional: both demo scripts import pytrt at module
import time, so help succeeds only after a compatible extension has been
built and its TensorRT/CUDA libraries can load.*.engine, *.so, pytrt.cpp, and build directories out of
this runtime skill tree. The supplied validator is read-only.| Need | Entry point | Required generated assets |
|---|---|---|
| Classify an image or stream | trt_googlenet.py | googlenet/deploy.engine, built pytrt |
| Detect faces and landmarks | trt_mtcnn.py | mtcnn/det1.engine, det2.engine, det3.engine, built pytrt |
| Build GoogLeNet engine | googlenet/create_engine.cpp | deploy.prototxt, deploy.caffemodel, TensorRT Caffe parser |
| Build MTCNN engines | mtcnn/create_engines.cpp | three det*_relu prototxt/weights, TensorRT Caffe parser |
| Build Python bridge | root Makefile → setup.py | Cython, NumPy, CUDA/TensorRT headers and libraries |
| Check source/assets without mutation | scripts/validate-legacy-model-assets.py | Python standard library only |
If the request is to modernize these demos, export them, or replace Caffe, stop at the compatibility boundary and describe the migration separately; do not silently reinterpret a legacy workflow as modern TensorRT support.
googlenet/, run make then
./create_engine; from mtcnn/, run make then ./create_engines. The
programs serialize and immediately deserialize engines and print binding
information. A successful compiler invocation alone is insufficient.pytrt. From the repository root, run make PYTHON=python3.
This invokes setup.py build_ext -if, compiles the Cython module against
trtNet.cpp, and removes only the temporary build/ directory. The
resulting extension is generated at the root and is intentionally not part
of this skill.--image with a local image and keep
the process in a display-capable session. Image input repeats indefinitely;
press Esc to stop. Use --copy_frame for live sources if inference can
outpace capture and the displayed frame is modified in place.prob tensor with 1000 scores and
display top three labels. MTCNN must return (N,5) boxes and (N,10)
landmarks, with no NaNs and coordinates clipped to the image bounds. Record
the exact TensorRT version, GPU, source commit, engine build command, and
input mode with the result.Do not run install*.sh, download_yolo.sh, sudo pip, or network fetches as
part of this workflow. Do not infer that an absent weight is safe to replace
with a random or newer model: descriptor/weight compatibility is required.
Use the read-only validator to distinguish missing assets from a broken build.
For failures, classify them as missing source/weight, toolchain/header/linker,
engine deserialization/version, extension import, input/GStreamer, or model
post-processing. See troubleshooting.md.
minsize=40, predict that TrtMtcnn.detect rescales to at most
1280×720, raises the effective minimum size but never below 40, converts
BGR→RGB, and applies PNet/RNet/ONet thresholds 0.7/0.6/0.7. Confirm that
a caller asking for minsize=32 is rejected rather than silently accepted.pytrt, use the validator to report source/model
readiness with generated-runtime warnings; explain why both demo --help
commands remain blocked until a compatible extension and engines exist.