# Roboflow Inference - API problem

**URL:** https://discuss.roboflow.com/t/roboflow-inference-api-problem/9193
**Category:** 🤝  Community Help
**Created:** [March 25, 2025, 1:03am UTC](https://discuss.roboflow.com/t/roboflow-inference-api-problem/9193 "2025-03-25T01:03:42Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Larry](https://avatars.discourse-cdn.com/v4/letter/l/47e85d/32.png) [@Larry](https://discuss.roboflow.com/u/Larry)
#### Post date: [March 25, 2025, 1:03am UTC](https://discuss.roboflow.com/t/roboflow-inference-api-problem/9193/1 "2025-03-25T01:03:42Z")

</div>

I’m trying to deploy a fine-tuned model (yard-wildlife/1) from my account to a Raspberry Pi (5). Following the instructions [found here](https://deploy-quickstart.roboflow.com/results.html#Fine-Tuned/Object%20Detection/On%20Edge%20Devices/Raspberry%20Pi/Image), I’ve installed inference, as well as exported my API key.

However, just running the small Python script ..

```auto
   import inference
   model = inference.get_model("yard-wildlife/1") 

```

.. yields an “API not authorized .. unauthorized access” error (even after revoking/regenerating a key)

(Note: inference.load\_roboflow\_model(), as shown in the link, doesn’t work .. this gives an ‘no attribute’ error .. so I just used get\_model() as noted in some other related posts).

Any guidance on to how to get my model deployed for inferencing on the Pi would be appreciated.

Thanks,  
Larry

---

<div class="post-metadata">

### Author: ![Larry](https://avatars.discourse-cdn.com/v4/letter/l/47e85d/32.png) [@Larry](https://discuss.roboflow.com/u/Larry)
#### Post date: [March 25, 2025, 8:57am UTC](https://discuss.roboflow.com/t/roboflow-inference-api-problem/9193/2 "2025-03-25T08:57:45Z")

</div>

I made a bit of progress by simply moving the API key within get\_model() as suggested in [this post](https://discuss.roboflow.com/t/all-models-run-on-your-own-hardware-or-not/8037). However, updating/amending my code snippet to ..

```auto
import inference
model = inference.get_model(model_id="yard-wildlife/1", api_key="my_api_key")
results = model.infer(image="my_test_image")

print(results[0])

```

.. to run inference on a test image unleashes a torrent of dependencies warnings (?) and no apparent inference (on an image that works fine when just using Roboflow browser).

 ![output](https://canada1.discourse-cdn.com/flex029/uploads/roboflow1/original/2X/9/9e7ebb8a945f183adaad54cdb583ba999953a3b3.png)

So, one step forward, one step back ..

Larry

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex029/uploads/roboflow1/original/1X/bb6edbfa56d0cf2ee603f061e9e09103502cc8cc.png) [@system](https://discuss.roboflow.com/u/system)
#### Post date: [April 15, 2025, 8:58am UTC](https://discuss.roboflow.com/t/roboflow-inference-api-problem/9193/3 "2025-04-15T08:58:46Z")

</div>

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.
