@@ -31,33 +31,31 @@ RUN cargo build --release --features llama,vision,llama-cuda
3131RUN pip3 install requests
3232
3333# Create test script
34- RUN cat > /workspace/run_vision_tests.sh << 'EOF'
35- #!/bin/bash
36- set -e
37-
38- echo "🧪 Starting Vision Cross-Platform Tests"
39- echo "Platform: Linux x86_64 (CUDA)"
40- echo "================================="
41-
42- # Set test environment
43- export SHIMMY_VISION_MAX_LONG_EDGE=1024
44- export SHIMMY_VISION_MAX_PIXELS=2500000
45- export SHIMMY_VISION_AUTO_DOWNLOAD=1
46-
47- # Check CUDA availability
48- echo "🔍 Checking CUDA..."
49- nvidia-smi || echo "⚠️ CUDA not available in container"
50-
51- # Run the cross-compiled vision test
52- echo "🖼️ Running vision functionality tests..."
53- python3 scripts/test_cross_compiled_vision.py \
54- --binary ./target/release/shimmy \
55- --test-image assets/vision-samples/final-test.png \
56- --license "test-license-key" \
57- --output-report /workspace/test-results-linux-cuda.json
58-
59- echo "✅ Vision tests completed for Linux x86_64 (CUDA)"
60- EOF
34+ RUN echo '#!/bin/bash' > /workspace/run_vision_tests.sh && \
35+ echo 'set -e' >> /workspace/run_vision_tests.sh && \
36+ echo '' >> /workspace/run_vision_tests.sh && \
37+ echo 'echo "🧪 Starting Vision Cross-Platform Tests"' >> /workspace/run_vision_tests.sh && \
38+ echo 'echo "Platform: Linux x86_64 (CUDA)"' >> /workspace/run_vision_tests.sh && \
39+ echo 'echo "================================="' >> /workspace/run_vision_tests.sh && \
40+ echo '' >> /workspace/run_vision_tests.sh && \
41+ echo '# Set test environment' >> /workspace/run_vision_tests.sh && \
42+ echo 'export SHIMMY_VISION_MAX_LONG_EDGE=1024' >> /workspace/run_vision_tests.sh && \
43+ echo 'export SHIMMY_VISION_MAX_PIXELS=2500000' >> /workspace/run_vision_tests.sh && \
44+ echo 'export SHIMMY_VISION_AUTO_DOWNLOAD=1' >> /workspace/run_vision_tests.sh && \
45+ echo '' >> /workspace/run_vision_tests.sh && \
46+ echo '# Check CUDA availability' >> /workspace/run_vision_tests.sh && \
47+ echo 'echo "🔍 Checking CUDA..."' >> /workspace/run_vision_tests.sh && \
48+ echo 'nvidia-smi || echo "⚠️ CUDA not available in container"' >> /workspace/run_vision_tests.sh && \
49+ echo '' >> /workspace/run_vision_tests.sh && \
50+ echo '# Run the cross-compiled vision test' >> /workspace/run_vision_tests.sh && \
51+ echo 'echo "🖼️ Running vision functionality tests..."' >> /workspace/run_vision_tests.sh && \
52+ echo 'python3 scripts/test_cross_compiled_vision.py \' >> /workspace/run_vision_tests.sh && \
53+ echo ' --binary ./target/release/shimmy \' >> /workspace/run_vision_tests.sh && \
54+ echo ' --test-image assets/vision-samples/final-test.png \' >> /workspace/run_vision_tests.sh && \
55+ echo ' --license "test-license-key" \' >> /workspace/run_vision_tests.sh && \
56+ echo ' --output-report /workspace/test-results-linux-cuda.json' >> /workspace/run_vision_tests.sh && \
57+ echo '' >> /workspace/run_vision_tests.sh && \
58+ echo 'echo "✅ Vision tests completed for Linux x86_64 (CUDA)"' >> /workspace/run_vision_tests.sh
6159
6260RUN chmod +x /workspace/run_vision_tests.sh
6361
0 commit comments