| 834 | } |
| 835 | |
| 836 | bool clip_image_encode(const clip_ctx * ctx, const int n_threads, clip_image_f32 * img, float * vec) { |
| 837 | if (!ctx->has_vision_encoder) { |
| 838 | printf("This gguf file seems to have no vision encoder\n"); |
| 839 | return false; |
| 840 | } |
| 841 | |
| 842 | clip_image_f32_batch imgs{}; |
| 843 | imgs.size = 1; |
| 844 | imgs.data = img; |
| 845 | return clip_image_batch_encode(ctx, n_threads, &imgs, vec); |
| 846 | } |
| 847 | |
| 848 | bool clip_image_batch_encode(const clip_ctx * ctx, const int n_threads, const clip_image_f32_batch * imgs, float * vec) { |
| 849 |
no test coverage detected