Neurocuts
NeuroCuts is a deep RL algorithm for generating optimized packet classification trees.
Install / Use
/learn @neurocuts/NeurocutsREADME
NeuroCuts
NeuroCuts is a deep RL algorithm for generating optimized packet classification trees. See the preprint for an overview.
Running NeuroCuts
You can train a NeuroCuts policy for the small acl5_1k rule set using the following command. This should converge to an memory access time of 9-10 within 50k timesteps:
python run_neurocuts.py --rules=acl5_1k --fast
To monitor training progress, open tensorboard --logdir=~/ray_results and navigate to the web UI. The important metrics to pay attention to are rules_remaining_min (this must reach zero before the policy starts generating "valid" trees), memory_access_valid_min (access time metric for valid trees), bytes_per_rule_valid_min (bytes per rule metric for valid trees), and vf_explained_var (explained variance of the value function, which approaches 1 as the policy converges):

To kick off a full-scale training run, pass in a comma separated list of rule file names from the classbench directory and overrides for other hyperparameters. Example:
python run_neurocuts.py --rules=acl1_10k,fw1_10k,ipc1_10k \
--partition-mode=efficuts \
--dump-dir=/tmp/trees --num-workers=8 --gpu
Inspecting trees
You can visualize and check the state of generated trees by running inspect_tree.py <tree.pkl>. This requires that you specify the --dump-dir option when running NeuroCuts training.
Running baselines
You can run the HiCuts, HyperCuts, EffiCuts, and CutSplit baselines using run_baselines.py.
Related Skills
node-connect
346.4kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
107.2kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
346.4kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
346.4kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
