python3 -m verl.trainer.main_ppo \
    algorithm.adv_estimator=grpo \
    data.prompt_type="original" \
    data.system_prompt="general_qa" \
    data.train_files=datasets/VisionThink-General-Train \
    data.val_files=datasets/VisionThink-General-Val \
    data.train_batch_size=512 \
    data.max_prompt_length=8192 \
    data.max_response_length=8192 \
    data.image_key=images \
    data.mask_blank=False \
    data.acc_reward_weight=1.0 \
    data.format_reward_weight=0.5 \
    data.general_qa_reward_fn="general_qa_gpt" \
    data.gpt_extract_answer=False \
    data.return_raw_chat=True \
    data.gpt_threads=100 \
    reward_model.reward_manager=naive_multithreads \
    reward_model.log_rewards_separately=True \
    actor_rollout_ref.model.path=Qwen/Qwen2.5-VL-7B-Instruct \
    actor_rollout_ref.actor.optim.lr=1e-6 \
    actor_rollout_ref.model.use_remove_padding=True \
    actor_rollout_ref.actor.ppo_mini_batch_size=32 \
    actor_rollout_ref.actor.ppo_micro_batch_size_per_gpu=4 \
    actor_rollout_ref.actor.use_kl_loss=True \
    actor_rollout_ref.actor.kl_loss_coef=0.001 \
    actor_rollout_ref.actor.kl_loss_type=low_var_kl \
    actor_rollout_ref.actor.entropy_coeff=0.001 \
    actor_rollout_ref.model.enable_gradient_checkpointing=True \
    actor_rollout_ref.actor.fsdp_config.param_offload=False \
    actor_rollout_ref.actor.fsdp_config.optimizer_offload=False \
    actor_rollout_ref.rollout.log_prob_micro_batch_size_per_gpu=8 \
    actor_rollout_ref.rollout.tensor_model_parallel_size=2 \
    actor_rollout_ref.rollout.max_num_batched_tokens=32768 \
    actor_rollout_ref.rollout.name=vllm \
    actor_rollout_ref.rollout.gpu_memory_utilization=0.75 \
    actor_rollout_ref.rollout.enable_chunked_prefill=False \
    actor_rollout_ref.rollout.enforce_eager=False \
    actor_rollout_ref.rollout.free_cache_engine=False \
    actor_rollout_ref.rollout.n=16 \
    actor_rollout_ref.ref.log_prob_micro_batch_size_per_gpu=8 \
    actor_rollout_ref.ref.fsdp_config.param_offload=True \
    algorithm.kl_ctrl.kl_coef=0.001 \
    trainer.critic_warmup=0 \
    trainer.logger=['console','wandb'] \
    trainer.project_name='VisionThink' \
    trainer.experiment_name='Open_Source_GeneralQA_4O_Judge' \
    trainer.val_generations_to_log_to_wandb=128 \
    trainer.n_gpus_per_node=8 \
    trainer.nnodes=4 \
    trainer.save_freq=5 \
    trainer.default_local_dir=./trials/Open_Source_GeneralQA_4O_Judge \
    trainer.test_freq=5 \
    trainer.total_epochs=10 \
    trainer.log_training_rollouts_freq=5 \
    trainer.train_generations_to_log_to_wandb=256 \
    trainer.use_3drope=True \
    reward_model.log_rewards_separately=True \
    trainer.rejection_sample=True \
    trainer.rejection_sample_multiplier=1