TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #199 · 8 јан.

Многие из тех кто активно работал с Python2 несколько удивлены, почему в Python3 удобная функция reload() переехала из builtin в imp а потом и в importlib? Ну было же удобно! А теперь лишний импорт😖 Дело в том, что начиная с Python3.3 функция reload() переписана на Python вместо Cи. Что это нам даёт? 🔸 Такой код проще поддерживать и развивать 🔸 Python код легче читать, изучать и понимать. Сравните это ➡️ и это ➡️. 🔸 Как результат пункта 2, проще писать свои расширения импорта. Например, пользовательский импортёр с какой-либо хитрой логикой по аналогии с импортом из zip архивов. А есть ли у этого решения недостатки? Да, они всегда есть. 🔹 Так как это не builtin функция, её следует импортнуть перед использованием 🔹 Скорость замедлилась примерно на 5%. Очевидно, что это совершенно не критично. К тому же от версии к версии логика импорта будет оптимизироваться и ускоряться. В самом начале файла importlib/__init__.py мы видим такой импорт: import _imp # Just the builtin component, NOT the full Python module То есть часть функционала по прежнему написана на Си, но достаточно низкоуровневая. #basic

Hashtags

Резултати

Пронајдени 1 слични објави

Пребарај: #f0f0f0

当前筛选 #f0f0f0清除筛选

Я тут планирую добавить редактор персонажей в будущих обновлениях Banana-Crunch. Он пригодится тебе, если работаешь со сценами или персонажами. Хочу сделать всё максимально просто, чтобы буквально в пару кликов можно было получить нужный результат: позы, эмоции, ракурсы, взаимодействия и примеры. А пока делюсь частью инструкций и промптов, которые ты уже можешь использовать в работе. Подготовка к модельному ракурсу: You are an expert fashion photographer AI. Transform the person in this image into a full-body fashion model photo suitable for an e-commerce website. The background must be a clean, neutral studio backdrop (light gray, #f0f0f0). The person should have a neutral, professional model expression. Preserve the person's identity, unique features, and body type, but place them in a standard, relaxed standing model pose. The final image must be photorealistic. Return ONLY the final image. Важно! Выстави значение Ratio 9x16 Примерка одежды: You are an expert virtual try-on AI. You will be given a 'model image' and a 'garment image'. Your task is to create a new photorealistic image where the person from the 'model image' is wearing the clothing from the 'garment image'. Crucial Rules: 1. Complete Garment Replacement: You MUST completely REMOVE and REPLACE the clothing item worn by the person in the 'model image' with the new garment. No part of the original clothing (e.g., collars, sleeves, patterns) should be visible in the final image. 2. Preserve the Model: The person's face, hair, body shape, and pose from the 'model image' MUST remain unchanged. 3. Preserve the Background: The entire background from the 'model image' MUST be preserved perfectly. 4. Apply the Garment: Realistically fit the new garment onto the person. It should adapt to their pose with natural folds, shadows, and lighting consistent with the original scene. 5. Output: Return ONLY the final, edited image. Do not include any text. Важно! Сначала шмотка потом персонаж/модель Инструкция для позы: You are an expert fashion photographer AI. Take this image and regenerate it from a different perspective. The person, clothing, and background style must remain identical. The new perspective should be: "Jumping in the air, mid-action shot" [тут позу сам меняешь]. Return ONLY the final image. 😣 Хотел промпты получай! Жду тут твои реакции и коменты, а главное репосты ! #prompts | AcidCrunch