@googlefactss · Post #39892 · 30.09.2025 г., 03:09
In January 2013 an erotic film was mistakenly aired for several minutes in the background during a national TV news report in Sweden. @googlefactss#bizarre
Hashtags
TGINSIGHT SIMILAR POSTS
Изворен канал @pythonotes · Post #425 · 20 апр.
Недавно делал быстрый прототип асинхронного приложения в котором требовалось вызывать много синхронного кода. Да, я знаю, что это не лучший дизайн, но нужно было быстрое решение на один процесс и без очередей. Поэтому я выполнял код в потоках. Выглядело это примерно так: from fastapi.concurrency import run_in_threadpool async def execute(data: DataRequest) -> DataResponse: try: result = await run_in_threadpool(sync_function, data) return DataResponse(data=result) except Exception as e: return DataResponse( error=str(e), success=False, ) В общем работает нормально. Для всех вызовов под капотом используется общий тредпул, всё работает предсказуемо. Но потребовалось изменить количество запускаемых в пуле потоков (по умолчанию создается 40 воркеров). Так как дело происходит с FastAPI, делается это через lifespan используя настройки anyio: import anyio @asynccontextmanager async def lifespan(app: FastAPI): limiter = anyio.to_thread.current_default_thread_limiter() limiter.total_tokens = 100 yield # если вдруг нужно вернуть обратно limiter.total_tokens = 40 Зачем менять количество воркеров? - уменьшить, если оперативки мало (один тред занимает ~8мб) - увеличить чтобы выдержать нагрузку Если есть предложения получше при тех же вводных - предлагайте😉 #async
Hashtags
Пребарај: #bizarre
@googlefactss · Post #39892 · 30.09.2025 г., 03:09
In January 2013 an erotic film was mistakenly aired for several minutes in the background during a national TV news report in Sweden. @googlefactss#bizarre
Hashtags
@AiGenLabsStyles · Post #706 · 07.09.2024 г., 07:12
⭐️ --sref 1964343293 --s 250 #Photography#Surreal#Vibrant#Bizarre#StyleRandom#MidJourney#AiGenLabs#Ai 〰️〰️〰️〰️〰️ 👥TheLab - our community 🔥AiGenLabs - main channel
@AiGenLabsStyles · Post #726 · 10.09.2024 г., 09:14
⭐️ --sref 3414219761 #illustration#Bizarre#Dark#2d#StyleRandom#MidJourney#AiGenLabs#Ai 〰️〰️〰️〰️〰️ 👥TheLab - our community 🔥AiGenLabs - main channel
@googlefactss · Post #40837 · 21.03.2026 г., 05:57
There's an animal that smells like buttered popcorn. The binturong (Arctictis binturong), a Southeast Asian "bearcat," smells like buttered popcorn due to 2-acetyl-1-pyrroline (2-AP) in its urine, which it uses to mark territory. This chemical is the same aromatic compound produced when popcorn is popped. These arboreal, cat-like mammals are threatened by habitat loss. @googlefactss#animals#mammals#bizarre [read more....]
@AiGenLabsStyles · Post #815 · 27.09.2024 г., 13:28
⭐️ --sref 905263956 #illustration#2d#Dark#Bizarre#Cartoon#StyleRandom#MidJourney#AiGenLabs#Ai 〰️〰️〰️〰️〰️ 👥TheLab - our community 🔥AiGenLabs - main channel
@AiGenLabsStyles · Post #689 · 05.09.2024 г., 13:18
⭐️ --sref 2627355792 #illustration#2D#Vibrant#Bizarre#Cartoon#StyleRandom#MidJourney#AiGenLabs#Ai 〰️〰️〰️〰️〰️ 👥TheLab - our community 🔥AiGenLabs - main channel
@AiGenLabsStyles · Post #660 · 03.09.2024 г., 09:14
⭐️ --sref 3846026342 #illustration#Bizarre#Pastel#2d#Surreal#StyleRandom#MidJourney#AiGenLabs#Ai 〰️〰️〰️〰️〰️ 👥TheLab - our community 🔥AiGenLabs - main channel
@AiGenLabsStyles · Post #763 · 16.09.2024 г., 08:13
⭐️ --sref 4136665817 #illustration#2d#Cartoon#Vibrant#Dark#Bizarre#StyleRandom#MidJourney#AiGenLabs#Ai 〰️〰️〰️〰️〰️ 👥TheLab - our community 🔥AiGenLabs - main channel
@AiGenLabsStyles · Post #738 · 11.09.2024 г., 13:18
⭐️ --sref 2353362577 --s 888 #Cinematic#Surreal#Vibrant#Bizarre#Dark#Fantasy#StyleRandom#MidJourney#AiGenLabs#Ai 〰️〰️〰️〰️〰️ 👥TheLab - our community 🔥AiGenLabs - main channel
@AiGenLabsStyles · Post #676 · 04.09.2024 г., 13:18
🔝🔝 --sref 72314753 #illustration#3D#Vibrant#LowPoly#Bizarre#Cartoon#StyleRandom#MidJourney#AiGenLabs#Ai 〰️〰️〰️〰️〰️ 👥TheLab - our community 🔥AiGenLabs - main channel