-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrun_example.sh
More file actions
executable file
·63 lines (56 loc) · 1.7 KB
/
Copy pathrun_example.sh
File metadata and controls
executable file
·63 lines (56 loc) · 1.7 KB
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
52
53
54
55
56
57
58
59
60
61
62
63
#!/bin/bash
# Quick test script for 3DGS to Printer Converter
echo "======================================"
echo "3DGS to Printer Converter - Quick Test"
echo "======================================"
echo ""
# Check if Python is available
if ! command -v python3 &> /dev/null; then
echo "Error: python3 is not installed"
exit 1
fi
# Check if required packages are installed
echo "[1/4] Checking dependencies..."
if ! python3 -c "import numpy, scipy, open3d, rerun, PIL" 2> /dev/null; then
echo "Error: Required packages are not installed"
echo "Please run: pip install -r requirements.txt"
exit 1
fi
echo "✓ All dependencies installed"
echo ""
# Generate sample PLY if not exists
if [ ! -d "sample_ply" ]; then
echo "[2/4] Generating sample PLY files..."
python3 create_sample_ply.py
echo ""
else
echo "[2/4] Sample PLY files already exist"
echo ""
fi
# Run conversion on sphere
echo "[3/4] Running conversion on sphere.ply..."
echo "This will:"
echo " - Open Rerun visualization window"
echo " - Process 5 density scales (0.5x - 2.0x)"
echo " - Export slices to ./print_slices/"
echo ""
echo "Press Enter to continue, or Ctrl+C to cancel..."
read
python3 3dgs_to_printer.py sample_ply/sphere.ply \
--voxel-size 0.5 \
--density-scales 0.5 0.75 1.0 1.5 2.0 \
--export-scale 1.0 \
--output-dir ./print_slices \
--k-neighbors 8 \
--seed 42
echo ""
echo "[4/4] Done!"
echo ""
echo "Check the output:"
echo " - Rerun window: Interactive 3D visualization"
echo " - print_slices/: Generated PNG slices"
echo ""
echo "To test with different parameters:"
echo " python3 3dgs_to_printer.py sample_ply/sphere.ply --help"
echo ""
echo "======================================"