> For the complete documentation index, see [llms.txt](https://docs.clore.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.clore.ai/guides/guides_v2-hi/other-workloads/blender-rendering.md).

# Blender रेंडरिंग

Clore.ai पर GPU-त्वरित Blender 3D रेंडरिंग

CLORE.AI GPUs पर Blender का उपयोग करके 3D सीन और एनीमेशन रेंडर करें।

{% hint style="success" %}
सभी उदाहरण GPU सर्वरों पर चलाए जा सकते हैं, जिन्हें किराए पर लिया गया है [CLORE.AI मार्केटप्लेस](https://clore.ai/marketplace).
{% endhint %}

## CLORE.AI पर किराए पर लेना

1. विज़िट करें [CLORE.AI मार्केटप्लेस](https://clore.ai/marketplace)
2. GPU प्रकार, VRAM और कीमत के अनुसार फ़िल्टर करें
3. चुनें **ऑन-डिमांड** (स्थिर दर) या **स्पॉट** (बोली मूल्य)
4. अपना ऑर्डर कॉन्फ़िगर करें:
   * Docker इमेज चुनें
   * पोर्ट सेट करें (SSH के लिए TCP, वेब UI के लिए HTTP)
   * यदि आवश्यक हो तो environment variables जोड़ें
   * स्टार्टअप कमांड दर्ज करें
5. भुगतान चुनें: **CLORE**, **BTC**या **USDT/USDC**
6. ऑर्डर बनाएं और डिप्लॉयमेंट की प्रतीक्षा करें

### अपने सर्वर तक पहुँचें

* कनेक्शन विवरण यहाँ खोजें **मेरे ऑर्डर**
* वेब इंटरफ़ेस: HTTP पोर्ट URL का उपयोग करें
* SSH: `ssh -p <port> root@<proxy-address>`

## Blender के लिए GPU किराए पर क्यों लें?

* CPU की तुलना में जटिल सीन 10-50x तेज़ रेंडर करें
* और भी तेज़ रेंडरिंग के लिए कई GPU
* महंगे हार्डवेयर में निवेश करने की ज़रूरत नहीं
* केवल रेंडर समय के लिए भुगतान करें

## आवश्यकताएँ

| सीन की जटिलता | अनुशंसित GPU | VRAM    |
| ------------- | ------------ | ------- |
| सरल           | RTX 3070     | 8GB     |
| मध्यम         | RTX 3090     | 24GB    |
| जटिल          | RTX 4090     | 24GB    |
| प्रोडक्शन     | A100         | 40-80GB |

## त्वरित डिप्लॉय

**Docker इमेज:**

```
linuxserver/blender
```

या हेडलेस रेंडरिंग:

```
nytimes/blender:3.6-gpu-ubuntu22.04
```

**पोर्ट:**

```
22/tcp
3000/http
```

## हेडलेस रेंडरिंग सेटअप

**इमेज:**

```
nvidia/cuda:12.8.1-devel-ubuntu22.04
```

**कमांड:**

```bash
apt-get update && \\
apt-get install -y wget libxi6 libxxf86vm1 libxfixes3 libxrender1 libgl1 && \\
wget https://download.blender.org/release/Blender4.0/blender-4.0.2-linux-x64.tar.xz && \\
tar -xf blender-4.0.2-linux-x64.tar.xz && \\
mv blender-4.0.2-linux-x64 /opt/blender
```

## अपनी सेवा तक पहुँचना

डिप्लॉयमेंट के बाद, अपना `http_pub` URL यहाँ **मेरे ऑर्डर**:

1. पर जाएँ **मेरे ऑर्डर** पेज
2. अपने ऑर्डर पर क्लिक करें
3. खोजें `http_pub` URL (उदा., `abc123.clorecloud.net`)

उपयोग करें `https://YOUR_HTTP_PUB_URL` की बजाय `localhost` नीचे दिए गए उदाहरणों में।

## अपना प्रोजेक्ट अपलोड करें

### SCP के माध्यम से

```bash

# .blend फ़ाइल अपलोड करें
scp -P <port> myproject.blend root@<proxy>:/workspace/

# प्रोजेक्ट फ़ोल्डर अपलोड करें
scp -P <port> -r ./project/ root@<proxy>:/workspace/
```

### rsync के माध्यम से (बड़े प्रोजेक्ट्स)

```bash
rsync -avz --progress -e "ssh -p <port>" ./project/ root@<proxy>:/workspace/project/
```

## रेंडर कमांड

### एकल फ़्रेम

```bash
/opt/blender/blender -b /workspace/myproject.blend -o /workspace/output/frame_### -f 1 -- --cycles-device CUDA
```

### एनीमेशन (फ़्रेम रेंज)

```bash
/opt/blender/blender -b /workspace/myproject.blend -o /workspace/output/frame_### -s 1 -e 250 -a -- --cycles-device CUDA
```

### विशिष्ट फ़्रेम

```bash
/opt/blender/blender -b /workspace/myproject.blend -o /workspace/output/frame_### -f 1,50,100,150,200 -- --cycles-device CUDA
```

## रेंडर विकल्प

### रिज़ॉल्यूशन

```bash

# रिज़ॉल्यूशन ओवरराइड करें
blender -b file.blend -o //output/frame_### -x 1920 -y 1080 -a -- --cycles-device CUDA
```

### Python स्क्रिप्ट का उपयोग करें

```bash
blender -b file.blend --python render_setup.py -a
```

**render\_setup.py:**

```python
import bpy

# रेंडर इंजन सेट करें
bpy.context.scene.render.engine = 'CYCLES'

# डिवाइस सेट करें
bpy.context.preferences.addons['cycles'].preferences.compute_device_type = 'CUDA'

# सभी GPUs सक्षम करें
for device in bpy.context.preferences.addons['cycles'].preferences.devices:
    device.use = True

# सैंपल सेट करें
bpy.context.scene.cycles.samples = 128

# रिज़ॉल्यूशन सेट करें
bpy.context.scene.render.resolution_x = 1920
bpy.context.scene.render.resolution_y = 1080

# आउटपुट सेटिंग्स
bpy.context.scene.render.image_settings.file_format = 'PNG'
```

## मल्टी-GPU रेंडरिंग

कई GPUs वाले सर्वरों के लिए:

```python
import bpy

# CUDA सक्षम करें
prefs = bpy.context.preferences.addons['cycles'].preferences
prefs.compute_device_type = 'CUDA'

# डिवाइस रिफ्रेश करें
prefs.get_devices()

# सभी GPUs सक्षम करें
for device in prefs.devices:
    if device.type == 'CUDA':
        device.use = True
        print(f"Enabled: {device.name}")
```

## रेंडर फ़ार्म शैली (कई सर्वर)

कई सर्वर किराए पर लें और फ़्रेम विभाजित करें:

**सर्वर 1:**

```bash
blender -b project.blend -o //output/frame_### -s 1 -e 100 -a
```

**सर्वर 2:**

```bash
blender -b project.blend -o //output/frame_### -s 101 -e 200 -a
```

**सर्वर 3:**

```bash
blender -b project.blend -o //output/frame_### -s 201 -e 300 -a
```

फिर रेंडर को स्थानीय रूप से संयोजित करें।

## Eevee रेंडरिंग (तेज़)

रीयल-टाइम गुणवत्ता के लिए:

```bash
blender -b file.blend -E BLENDER_EEVEE -o //output/frame_### -a
```

## OptiX समर्थन (RTX GPUs)

RTX रे ट्रेसिंग के लिए:

```python
import bpy
prefs = bpy.context.preferences.addons['cycles'].preferences
prefs.compute_device_type = 'OPTIX'  # CUDA के बजाय
```

## स्वचालित रेंडर स्क्रिप्ट

**render.sh:**

```bash
#!/bin/bash
BLEND_FILE=$1
START_FRAME=$2
END_FRAME=$3
OUTPUT_DIR=/workspace/output

mkdir -p $OUTPUT_DIR

/opt/blender/blender -b $BLEND_FILE \\
    -o ${OUTPUT_DIR}/frame_### \\
    -s $START_FRAME \\
    -e $END_FRAME \\
    -a \\
    -- --cycles-device CUDA

echo "रेंडरिंग पूरी हुई!"
ls -la $OUTPUT_DIR
```

उपयोग:

```bash
chmod +x render.sh
./render.sh /workspace/myproject.blend 1 250
```

## रेंडर प्रगति की निगरानी

### आउटपुट फ़ोल्डर देखें

```bash
watch -n 5 'ls -la /workspace/output/ | tail -20'
```

### Blender आउटपुट

Blender फ़्रेम की प्रगति stdout पर प्रिंट करता है:

```
Fra:1 Mem:1234.56M (Peak 1500.00M) | Time:00:01.23 | Remaining:04:32.10 | Mem:567.89M, Peak:890.12M | Scene, View Layer | Sample 64/128
```

## रेंडर किए गए फ़्रेम डाउनलोड करें

```bash

# सभी फ़्रेम डाउनलोड करें
scp -P <port> -r root@<proxy>:/workspace/output/ ./renders/

# विशिष्ट फ़्रेम डाउनलोड करें
scp -P <port> root@<proxy>:/workspace/output/frame_001.png ./

# rsync के साथ सिंक करें
rsync -avz --progress -e "ssh -p <port>" root@<proxy>:/workspace/output/ ./renders/
```

## वीडियो एन्कोडिंग

फ़्रेम रेंडर होने के बाद, वीडियो में एन्कोड करें:

```bash

# ffmpeg इंस्टॉल करें
apt-get install -y ffmpeg

# MP4 में एन्कोड करें
ffmpeg -framerate 24 -i /workspace/output/frame_%03d.png -c:v libx264 -pix_fmt yuv420p output.mp4

# ProRes में एन्कोड करें (उच्च गुणवत्ता)
ffmpeg -framerate 24 -i /workspace/output/frame_%03d.png -c:v prores_ks -profile:v 3 output.mov
```

## प्रदर्शन सुझाव

### गति के लिए अनुकूलित करें

```python

# पूर्वावलोकन के लिए सैंपल कम करें
bpy.context.scene.cycles.samples = 64

# अनुकूली सैंपलिंग का उपयोग करें
bpy.context.scene.cycles.use_adaptive_sampling = True
bpy.context.scene.cycles.adaptive_threshold = 0.01

# बाउंस सीमित करें
bpy.context.scene.cycles.max_bounces = 8
```

### मेमोरी अनुकूलन

```python

# उच्च रिज़ॉल्यूशन के लिए टाइल्ड रेंडरिंग का उपयोग करें
bpy.context.scene.render.use_persistent_data = True

# टाइल आकार सेट करें
bpy.context.scene.cycles.tile_size = 256  # GPU के लिए
```

## रेंडर समय के अनुमान

| सीन       | GPU      | रिज़ॉल्यूशन | सैंपल | समय/फ़्रेम |
| --------- | -------- | ----------- | ----- | ---------- |
| सरल       | RTX 3090 | 1080p       | 128   | \~30 सेकंड |
| मध्यम     | RTX 3090 | 1080p       | 256   | \~2min     |
| जटिल      | RTX 4090 | 4K          | 512   | \~10min    |
| प्रोडक्शन | A100     | 4K          | 1024  | \~20min    |

## लागत गणना

**उदाहरण: 250 फ़्रेम की एनीमेशन**

```
GPU: RTX 4090
प्रति फ़्रेम समय: 2 मिनट
कुल रेंडर समय: 500 मिनट = 8.3 घंटे
प्रति घंटा दर: $0.04
कुल लागत: ~$0.33
```

## समस्या निवारण

### "CUDA डिवाइस नहीं मिला"

```python

# उपलब्ध डिवाइस जांचें
import bpy
prefs = bpy.context.preferences.addons['cycles'].preferences
prefs.compute_device_type = 'CUDA'
prefs.get_devices()
for d in prefs.devices:
    print(d.name, d.type)
```

{% hint style="danger" %}
**मेमोरी समाप्त**
{% endhint %}

* टेक्सचर रिज़ॉल्यूशन कम करें
* छोटा टाइल आकार उपयोग करें
* "persistent data" सक्षम करें
* सरल शेडर का उपयोग करें

### धीमी रेंडरिंग

* जांचें कि GPU उपयोग हो रहा है (nvidia-smi)
* सीन ज्योमेट्री को अनुकूलित करें
* कम सैंपल के साथ डीनोइज़िंग का उपयोग करें

## अगले चरण

* पोस्ट-प्रोसेसिंग के लिए Jupyter चलाएँ
* [AI वीडियो जनरेशन](/guides/guides_v2-hi/video-generation/ai-video-generation.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.clore.ai/guides/guides_v2-hi/other-workloads/blender-rendering.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
