أرخايف | صفحة المشروع
Yunzhi Zhang، Zizhang Li، Matt Zhou، Shangzhe Wu، Jiajun Wu. arXiv الطباعة المسبقة 2024.

conda create --name sclg python=3.11 conda activate sclg pip install mitsuba # if you run into segmentation fault, you might need specific mitsuba versions # e.g., `pip install --force-reinstall mitsuba==3.5.1` on MacOS pip install unidecode Pillow anthropic transforms3d astor ipdb scipy jaxtyping imageio # required for minecraft renderer pip install spacy python -m spacy download en_core_web_md pip install --force-reinstall numpy==1.26.4 # to be compatible with transforms3d git clone https://github.com/zzyunzhi/scene-language.git cd scene-language pip install -e .
احصل على مفتاح Anthropic API الخاص بك باتباع الوثائق الرسمية وأضفه إلى engine/key.py :
ANTHROPIC_API_KEY = 'YOUR_ANTHROPIC_API_KEY' OPENAI_API_KEY = 'YOUR_OPENAI_API_KEY' # optional, required for `LLM_PROVIDER='gpt'`
بشكل افتراضي، نستخدم Claude 3.5 Sonnet. يمكنك التبديل إلى نماذج اللغات الأخرى عن طريق تعيين LLM_PROVIDER في engine/constants.py .
python scripts/run.py --tasks " a chessboard with a full set of chess pieces "
سيتم حفظ العروض في ${PROJ_ROOT}/scripts/outputs/run_${timestep}_${uuid}/${scene_name}_${uuid}/${sample_index}/renderings/*.gif .
نتائج المثال (المخرجات الأولية هنا):
| "رقعة شطرنج بها مجموعة كاملة من قطع الشطرنج" | "لوحة سودوكو 9x9 مملوءة جزئيًا بالأرقام" | "مشهد مستوحى من إيغون شيلي" | "الكولوسيوم الروماني" | "دمية العنكبوت" |
|---|---|---|---|---|
![]() | ![]() | ![]() | ![]() | ![]() |
ENGINE_MODE=minecraft python scripts/run.py --tasks " a detailed cylindrical medieval tower "
يتم حفظ المشاهد التي تم إنشاؤها كملفات json في ${PROJ_ROOT}/scripts/outputs/run_${timestep}_${uuid}/${scene_name}_${uuid}/${sample_index}/renderings/*.json . للتصور، قم بتشغيل الأمر التالي:
python viewers/minecraft/run.py
ثم افتح http://127.0.0.1:5001 في متصفحك واسحب ملفات json التي تم إنشاؤها إلى صفحة الويب.
نتائج المثال (المخرجات الأولية هنا):
| ""بيت الساحرة في عيد الهالوين"" | "برج أسطواني مفصل من العصور الوسطى" | "نموذج تفصيلي لبيكاتشو" | "ستونهنج" | "معبد يوناني" |
|---|---|---|---|---|
![]() | ![]() | ![]() | ![]() | ![]() |
python scripts/run.py --tasks ./resources/examples/ * --cond image --temperature 0.8
يسرد الجدول التالي الوظائف المساعدة المحددة في هذا الملف وفقًا للتعبيرات المحددة في اللغة الخاصة بالمجال (DSL) (الجدولان 2 و5 من الورقة):
| تطبيق | دي اس ال |
|---|---|
register | bind |
library_call | call |
primitive_call | call |
loop | union-loop |
concat_shapes | union |
transform_shape | transform |
rotation_matrix | rotation |
translation_matrix | translate |
scale_matrix | scale |
reflection_matrix | reflect |
compute_shape_center | compute-shape-center |
compute_shape_min | compute-shape-min |
compute_shape_max | compute-shape-max |
compute_shape_sizes | compute-shape-sizes |
تسمح لك قاعدة التعليمات البرمجية الحالية بإنشاء مشاهد ثلاثية الأبعاد باستخدام مطالبات نصية أو صورية. سيتم دعم المهام والعارضين الآخرين المذكورين في الورقة في التحديثات المستقبلية.
يرجى إرسال العلاقات العامة أو مراسلتنا عبر البريد الإلكتروني إذا كانت لديك طلبات ميزات أو اقتراحات للتحسينات أو ترغب في مشاركة نتائجك.
إذا وجدت هذا العمل مفيدًا، فيرجى التفكير في الاستشهاد بمقالتنا:
@article { zhang2024scenelanguage , title = { The Scene Language: Representing Scenes with Programs, Words, and Embeddings } , author = { Yunzhi Zhang and Zizhang Li and Matt Zhou and Shangzhe Wu and Jiajun Wu } , year = { 2024 } , journal = { arXiv preprint arXiv:2410.16770 } , }