File size: 1,703 Bytes
9df0059 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | #!/bin/bash
# Quick test with only 5 bedroom samples to verify the fix works
cd /home/v-meiszhang/amlt-project/DiffuScene/scripts
exp_dir="../pretrained/pretrained_diffusion"
json_file="/home/v-meiszhang/amlt-project/DiffuScene/training_data_with_content_v3.1.json"
config="../config/text/diffusion_bedrooms_instancond_lat32_v_bert.yaml"
exp_name="bedrooms_bert"
weight_file="$exp_dir/$exp_name/model_32000"
threed_future="/home/v-meiszhang/backup/diffuscene/3d_front_processed/threed_future_model_bedroom.pkl"
output_dir="$exp_dir/$exp_name/quick_test"
echo "========================================"
echo "Quick Test: 5 bedroom samples"
echo "========================================"
echo ""
python test_custom_text.py \
$config \
$output_dir \
$threed_future \
$json_file \
--weight_file $weight_file \
--n_sequences 5 \
--max_sentences 3 \
--clip_denoised \
--no_texture \
--without_floor
echo ""
echo "========================================"
echo "Test complete!"
echo "========================================"
echo ""
# Check if results file was created successfully
if [ -f "$output_dir/test_results.json" ]; then
echo "✓ Results file created: $output_dir/test_results.json"
echo ""
echo "Checking file integrity..."
python -c "import json; f=open('$output_dir/test_results.json'); data=json.load(f); print(f'✓ JSON valid! Found {len(data[\"results\"])} results'); f.close()"
echo ""
echo "First result:"
python -c "import json; f=open('$output_dir/test_results.json'); data=json.load(f); print(json.dumps(data['results'][0], indent=2)[:500]); f.close()"
else
echo "✗ Results file not found!"
exit 1
fi
|