From the repository root, build the demo environment container:
docker build -t ml-compiler-opt-llvm docs/llvm/
Run the container with volume mounts to persist corpus data, training logs, and checkpoints locally. This enables running TensorBoard on the host to monitor training.
docker run -it \ -v "$(pwd):/work/ml-compiler-opt" \ -v "$(pwd)/local_logs:/work/corpus/" \ ml-compiler-opt-llvm /bin/bash
Inside the container, execute the entire end-to-end pipeline:
./docs/llvm/run_everything.sh
To monitor the training progress using TensorBoard, run the following command on your host machine pointing to the mounted logs directory:
tensorboard --logdir local_logs
If you want to understand or customize the flags used in the training pipeline scripts (like train_bc.py), you can:
--help: Use the --help flag with any of the Python scripts to print all available command-line flags and their descriptions:PYTHONPATH=. python3 compiler_opt/rl/train_bc.py --help