> For the complete documentation index, see [llms.txt](https://docs.roboflow.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.roboflow.com/deployment/ja/self-hosted/inference-server/install/raspberry-pi.md).

# Raspberry Pi にインストール

Docker を使って 64 ビットの Raspberry Pi 4 または 5 に Roboflow Inference Server をインストールし、期待できる性能を説明します。

このページの Docker の例では、ポート 9001 を localhost に公開しています。別のマシン上のクライアントの場合は、意図的にマッピングを到達可能なホストアドレスに変更し、設定してください [サーバーアクセス](/deployment/ja/self-hosted/inference-server/configuration/security.md#restrict-network-access).

推論は Raspberry Pi 4 Model B と Raspberry Pi 5 で動作します。ただし、使用するのは [オペレーティングシステムの64ビット版](https://www.raspberrypi.com/software/operating-systems/). SD カードの容量が十分にある場合は、64ビット版の「デスクトップと推奨ソフトウェア付き Raspberry Pi OS」を推奨します。

64ビット OS をインストールしたら、 [Docker をインストールします](https://docs.docker.com/engine/install/debian/)その後、Inference CLI を使用して適切な Inference Docker コンテナを自動的に選択、設定、起動します:

```bash
pip install inference-cli
inference server start
```

{% hint style="warning" %}
**デフォルトでは、このデバイスからのみサーバーにアクセスできます。** `inference server start` ポートを公開します `9001` 上の `127.0.0.1`、そのため同じネットワーク上のラップトップや他のホストからの要求は拒否されます。LAN 経由でアクセスするには、次のように起動します `inference server start --bind-address 0.0.0.0` （またはコンテナのポートを次のように公開し `-p 0.0.0.0:9001:9001`） - そして [セルフホストサーバーの保護](/deployment/ja/self-hosted/inference-server/configuration/security.md) まずお読みください。デフォルトではサーバーに認証がなく、Workflows のカスタム Python ブロックを実行するためです。
{% endhint %}

## ハードウェア アクセラレーション

Inference はまだ Raspberry Pi 上のハードウェア アクセラレーションをサポートしていません。"Roboflow 3.0 Fast" の物体検出モデル（"nano" サイズの YOLO モデルに相当）では、Pi 4 で約 1 FPS、Pi 5 で約 4 FPS 程度になると見込んでください。

Segment Anything のような大きなモデルや、Florence-2 のような VLM は、Pi の計算性能では厳しいでしょう。より高いフレームレートやより大きなモデルが必要な場合は、 [NVIDIA Jetson](/deployment/ja/self-hosted/inference-server/install/jetson.md).

## コンテナを手動で起動する

コンテナ設定をより細かく制御したい場合は、自分で起動してください:

```bash
sudo docker run -d \\
    --name inference-server \\
    --read-only \\
    -p 127.0.0.1:9001:9001 \
    --volume ~/.inference/cache:/tmp:rw \\
    --security-opt="no-new-privileges" \\
    --cap-drop="ALL" \\
    --cap-add="NET_BIND_SERVICE" \\
    roboflow/roboflow-inference-server-cpu:latest
```

## Docker Compose

アプリケーションで Docker Compose を使用している場合、同等の YAML は次のとおりです:

```yaml
version: "3.9"

services:
  inference-server:
    container_name: inference-server
    image: roboflow/roboflow-inference-server-cpu:latest

    read_only: true
    ports:
      - "127.0.0.1:9001:9001"

    volumes:
      - "${HOME}/.inference/cache:/tmp:rw"

    security_opt:
      - no-new-privileges
    cap_drop:
      - ALL
    cap_add:
      - NET_BIND_SERVICE
```

{% hint style="info" %}
Roboflow Enterprise プランには [Kubernetes デプロイメント用の Helm チャート](https://github.com/roboflow/inference/tree/main/inference/enterprise/helm-chart) Kubernetes デプロイメント、OT ネットワーク向けのネットワーキングソリューション、カスタマイズされたサポートおよびインストールパッケージ向けです。 [営業チームにお問い合わせください](https://roboflow.com/sales) 詳細をご確認ください。
{% endhint %}

## 次の手順

* [モデルを実行する](/deployment/ja/self-hosted/self-hosted.md#run-model-locally) 新しいサーバーに対して。
* [Docker の設定オプション](/deployment/ja/self-hosted/inference-server/configuration/docker-configuration.md) ポート、キャッシュ、モデルの上限について。
* [セルフホストサーバーの保護](/deployment/ja/self-hosted/inference-server/configuration/security.md) localhost の外に公開する前に。
