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

TGINSIGHT SIMILAR POSTS

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

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

Три способа выполнить множество задач с asyncio Функция для примера: async def do_it(n): await asyncio.sleep(random.uniform(0.5, 1)) return n 1. Последовательный вызов async def main(): for i in range(100): result = await do_it(i) Такой вызов имеет смысл только тогда, когда результат одной задачи требуется для вызова следующей. Если они независимы, то это антипаттерн, так как аналогичен простому синхронному вызову по очереди. 2. Упорядоченный результат async def main(): tasks = [do_it(i) for i in range(100)] results = await asyncio.gather(*tasks) Выполняет корутины конкурентно и возвращает результат в виде списка. Полезен когда требуется получить результаты в том же порядке в котором задачи отправлены. 3. Результат по мере готовности tasks = [asyncio.create_task(do_it(i)) for i in range(100)] for cor in asyncio.as_completed(tasks): result = await cor Так же выполняет корутины конкурентно, но не гарантирует порядок. Результат возвращается по мере готовности, каждый отдельно. Полезен когда нужно обработать любой ответ как можно скорее. #async

Hashtags

Резултати

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

Пребарај: #vulkan

当前筛选 #vulkan清除筛选
Android Broadcast

@android_broadcast · Post #8812 · 15.03.2025 г., 08:23

Какие преимущества даст переход на Vulkan для отрисовки UI в Android? 🚀Производительность: Vulkan обеспечивает более эффективную работу с GPU и CPU, сокращая оверхед и повышая FPS. Лучше работает во множество поток 🔋Энергоэффективность: Снижение нагрузки на процессор ведёт к заметной экономии заряда аккумулятора. ⛏️Контроль и гибкость: Разработчики получают больше возможностей для тонкой настройки графического рендеринга и оптимизации приложений. ✅Кроссплатформенность: Vulkan поддерживается на многих платформах, что облегчает переносимость кода и улучшает совместимость приложений. Аналогичный переход сделала Apple, когда отказалась от OpenGL ES в iOS, заменив его на API Metal, которое призвано выполнять аналогичные функции, что и Vulkan. #android#vulkan

Android Broadcast

@android_broadcast · Post #8811 · 15.03.2025 г., 06:00

‼️Vulkan станет основной технологий для рендеринга UI в Android Начиная, с Android 17 большая часть устройств перейдет на рендеринг UI с OpenGL ES на Vulkan, а поддержку OpenGL будет убрана и станет доступна через ANGLE для трансляции команд в Vulkan. #android#android17#vulkan#opengl

GitHub Trends

@githubtrending · Post #15604 · 06.04.2026 г., 11:30

#java#minecraft#minecraft_mod#vulkan#vulkan_renderer VulkanMod is a Fabric mod that replaces Minecraft Java's old OpenGL renderer with a modern Vulkan 1.2 engine, cutting CPU overhead, boosting GPU performance, and adding features like Wayland support and chunk optimizations for much higher FPS and smoother gameplay. Install Fabric loader, download the .jar from Modrinth or CurseForge, and drop it in your .minecraft/mods folder to enjoy lag-free worlds and better hardware use right away—perfect for high-res packs or busy servers. https://github.com/xCollateral/VulkanMod

GitHub Trends

@githubtrending · Post #14810 · 08.06.2025 г., 14:00

#rust#d3d12#gpu#hacktoberfest#metal#opengl#rust#vulkan#webgpu **wgpu** is a powerful graphics library for Rust that works on many platforms, including Windows, macOS, Linux, and the web. It supports various graphics APIs like Vulkan, Metal, and DirectX. This library is safe and portable, making it easy to create graphics and compute applications. Using **wgpu**, you can build fast and efficient graphics programs that run on different devices and browsers, which is beneficial for developers who want to create cross-platform applications. https://github.com/gfx-rs/wgpu

GitHub Trends

@githubtrending · Post #14766 · 30.05.2025 г., 12:30

#cplusplus#best_practices#cpp#graphics#graphics_programming#khronos#tutorials#vulkan#vulkan_api#vulkan_samples Vulkan is a powerful tool for creating high-performance graphics and computing applications. It helps developers control the GPU better, which can lead to faster and more efficient performance compared to older systems like OpenGL. Vulkan is special because it works on many different platforms, such as Windows, Linux, and Android. This means developers can create applications that run smoothly across various devices. The Vulkan Samples provide resources and tutorials to help developers learn and optimize their applications, making it easier to create high-quality graphics and computing experiences. https://github.com/KhronosGroup/Vulkan-Samples

GitHub Trends

@githubtrending · Post #14659 · 01.05.2025 г., 15:30

#cplusplus#arm#convolution#deep_learning#embedded_devices#llm#machine_learning#ml#mnn#transformer#vulkan#winograd_algorithm MNN is a lightweight and efficient deep learning framework that helps run AI models on mobile devices and other small devices. It supports many types of AI models and can handle tasks like image recognition and language processing quickly and locally on your device. This means you can use AI features without needing to send data to the cloud, which improves privacy and speed. MNN is used in many apps, including those from Alibaba, and supports various platforms like Android and iOS. It also helps reduce the size of AI models, making them faster and more efficient. https://github.com/alibaba/MNN