fix: add cd to SLIME_ROOT and derive MEGATRON_ROOT dynamically#21
Open
JasonOA888 wants to merge 2 commits intoGen-Verse:mainfrom
Open
fix: add cd to SLIME_ROOT and derive MEGATRON_ROOT dynamically#21JasonOA888 wants to merge 2 commits intoGen-Verse:mainfrom
JasonOA888 wants to merge 2 commits intoGen-Verse:mainfrom
Conversation
Fixes Gen-Verse#5 ## Summary - train_async.py requires the working directory to be slime/, otherwise it cannot find the necessary modules and configs - Added cd "${SLIME_ROOT}" after sourcing the model config in all three training scripts ## Changes - openclaw-rl/run_qwen3_4b_openclaw_rl.sh - openclaw-opd/run_qwen3_4b_openclaw_opd.sh - openclaw-opd/run_qwen3_4b_openclaw_opd_topk.sh Each script now includes: ```bash source "${SLIME_ROOT}/scripts/models/qwen3-4B.sh" cd "${SLIME_ROOT}" echo "Current Working Directory: $(pwd)" ``` ## Test plan - [x] Verified cd command is added after source - [x] Verified SLIME_ROOT variable is correctly expanded
Fixes Gen-Verse#3 ## Summary - Replace hardcoded /absolute/path/to/OpenClaw-RL/Megatron-LM/ with dynamically computed MEGATRON_ROOT - Computes MEGATRON_ROOT using the same cd && pwd pattern as SLIME_ROOT ## Changes - openclaw-rl/run_qwen3_4b_openclaw_rl.sh - openclaw-opd/run_qwen3_4b_openclaw_opd.sh Each script now includes: ```bash MEGATRON_ROOT="$(cd -- "${SCRIPT_DIR}/../Megatron-LM" &>/dev/null && pwd)" ... "PYTHONPATH": "${MEGATRON_ROOT}:${SCRIPT_DIR}:${SLIME_ROOT}" ``` ## Test plan - [x] Verified SCRIPT_DIR/../Megatron-LM resolves correctly - [x] Pattern matches existing SLIME_ROOT computation - [x] Shell quoting correct in JSON string
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #5, Fixes #3
Summary
cd "${SLIME_ROOT}"before train_async.py callsChanges
Test plan