【Macユーザー向け】Kritaとkrita-ai-diffusionのインストールとエラー解決編

Kritaのインストール方法
Kritaをインストールするには、公式サイトからダウンロードを行います。
1. dmgファイルをダウンロードします。
インストール手順は非常にシンプルです!
2. インストール
ダウンロードしたファイルを開き、Kritaをアプリケーションフォルダにドラッグ&ドロップするだけで完了です。

krita-ai-diffusionのインストール手順
1. プラグインのダウンロード
krita-ai-diffusionのプラグインはこちらのGitHubページから入手できます。
最新バージョン(例: Version 1.29.0)をダウンロードしましょう。
• ファイル名:krita_ai_diffusion-1.29.0.zip

• ダウンロード方法:Controlキーを押しながらリンクをクリックし、「Download Linked File」を選択します。
2. プラグインをKritaにインポート
Kritaを起動し、メニューから Tools > Scripts > Import Python Plugin from File を選択します。

ダウンロードしたkrita_ai_diffusion-1.29.0.zipを選択してください。
3. Kritaの再起動
Kritaを再起動し、新しいキャンバスを作成します(例: サイズ 500×500)。
4. AI Image Generationの設定
メニューバーの Settings > Dockers > AI Image Generation をクリックすると、画面右下にドッキングパネルが表示されます。

パネル内の「Configure」をクリックし、「Install」を選択してください。

⚠️ 注意:インストールには約10GBの空き容量が必要です。
【Macでのエラー解決方法】Server Runningエラーへの対処
Mac環境では、インストール後に以下のエラーが表示される場合があります。

Server running – Connection error: Connection established, but the server is missing one or more custom node
このエラーを解決するには、次の手順を行ってください。
1. ターミナルを開き作業ディレクトリに移動
下記コマンドをターミナルで実行します。
cd "/Users/[Your Name]/Library/Application Support/krita/ai_diffusion/server"
※ [Your Name] は自分のユーザー名に置き換えてください。
2. 既存のディレクトリを削除
問題の原因となるディレクトリを削除します。
rm -rf comfyui-tooling-nodes
3. リポジトリを再クローン
正しいファイルを再ダウンロードします。
git clone https://github.com/Acly/comfyui-tooling-nodes
4. Kritaを再起動して設定を更新
Kritaを再起動後、右下の歯車アイコンをクリックして「Configure Image Diffusion」を開きます。

左メニューの「Connection」から一旦Server Runningを停止し、すべての項目をチェックして再インストールします。
最後に「Launch」をクリックしてサーバーを再起動してください。
これでMac環境でのエラーを解消し、生成AIを活用できるようになります!リアルタイム画像生成などの先進的な機能をぜひお楽しみください。
リアルタイム画像の参考です。左に絵を描くとAIが右下に書き直してくれます。面白いですね。

この手順を参考に、快適なAIライフをスタートさせましょう!