huggingface / candle

Minimalist ML framework for Rust
Apache License 2.0
15.05k stars 878 forks source link

Error in Moondream Example #2338

Closed iggyzuk closed 1 month ago

iggyzuk commented 1 month ago

Running command: cargo run --example moondream --release -- --prompt "What is the girl eating?" --image "./demo-1.jpg"

Results in this error: Error: shape mismatch for vision_encoder.projection.mlp.fc1.weight, expected: [8192, 1152], got: [8192, 2304]

Anyone know why the shapes don't match? Any fixes? Thanks.

LaurentMazare commented 1 month ago

Thanks for reporting this, this was caused by some recent changes in the moondream architecture, I've pinned the revision that we use from the HF repo so that this shouldn't happen anymore. #2340

iggyzuk commented 1 month ago

Nice one, thanks, works like a charm! 🎉