# On restart ZeroGPU not working but on CPU it works

**URL:** <https://discuss.huggingface.co/t/on-restart-zerogpu-not-working-but-on-cpu-it-works/164979>\
**Category:** Spaces\
**Created:** [July 29, 2025, 4:31pm UTC](https://discuss.huggingface.co/t/on-restart-zerogpu-not-working-but-on-cpu-it-works/164979 "2025-07-29T16:31:23Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![saptarshineilsinha](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/saptarshineilsinha/32/51857_2.png) [@saptarshineilsinha](https://discuss.huggingface.co/u/saptarshineilsinha)\
**Post date:** [July 29, 2025, 4:31pm UTC](https://discuss.huggingface.co/t/on-restart-zerogpu-not-working-but-on-cpu-it-works/164979/1 "2025-07-29T16:31:23Z")

</div>

With no changes after restarting the space I get this error on ZeroGPU:

example space : [StrawberryDiseaseDetector - a Hugging Face Space by PERCEIVE-Demos](https://huggingface.co/spaces/PERCEIVE-Demos/StrawberryDiseaseDetector)

# runtime error

## Exit code: ?. Reason:

Container logs:

```auto
===== Application Startup at 2025-07-29 16:27:34 =====

```

Previously it was working. Can someone help me with this? Seems to be an issue on the side of HuggingFace

---

<div class="post-metadata">

**Author:** ![John6666](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/john6666/32/27664_2.png) [@John6666](https://discuss.huggingface.co/u/John6666)\
**Post date:** [July 29, 2025, 9:48pm UTC](https://discuss.huggingface.co/t/on-restart-zerogpu-not-working-but-on-cpu-it-works/164979/2 "2025-07-29T21:48:45Z")

</div>

It started working after turning off the cache for Example for now.

```py
iface = gr.Interface(
    fn=process_input,
    inputs=[
        gr.Image(label="Upload Image", type="pil"), # File input as PIL Image
    ],
    outputs=gr.Image(type="pil", label="Output (Image)"), # Show output as an image
    examples=default_images,
    cache_examples=False, # <=
    title="Strawberry Disease Detection",
    description="This application detects diseases in strawberries using a trained YOLOX model. Upload an image, video, or use your webcam for analysis."
)

```

> **[app.py · PERCEIVE-Demos/StrawberryDiseaseDetector at main](https://huggingface.co/spaces/PERCEIVE-Demos/StrawberryDiseaseDetector/blob/main/app.py#L75)**
>
> We’re on a journey to advance and democratize artificial intelligence through open source and open science.

---

<div class="post-metadata">

**Author:** ![eitelk](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/eitelk/32/49534_2.png) [@eitelk](https://discuss.huggingface.co/u/eitelk)\
**Post date:** [July 30, 2025, 10:19am UTC](https://discuss.huggingface.co/t/on-restart-zerogpu-not-working-but-on-cpu-it-works/164979/3 "2025-07-30T10:19:41Z")

</div>

At least for me all the spaces are working again with ZeroGPU. 😍 I don’t know what Hugging Face has changed.
