• Patryk Wychowaniec's avatar
    interrogate: Fix CLIP-interrogation on CPU · 7157e5d0
    Patryk Wychowaniec authored
    Currently, trying to perform CLIP interrogation on a CPU fails, saying:
    
    ```
    RuntimeError: "slow_conv2d_cpu" not implemented for 'Half'
    ```
    
    This merge request fixes this issue by detecting whether the target
    device is CPU and, if so, force-enabling `--no-half` and passing
    `device="cpu"` to `clip.load()` (which then does some extra tricks to
    ensure it works correctly on CPU).
    7157e5d0
interrogate.py 6.64 KB