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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #239 · 3 мај

Один из самых удобных способов записать данные это использование готовых форматов, такие как JSON или YAML. Из плюсов такого подхода стоит отметить вот что: 🔸 готовый, повсеместно используемый и поддерживаемый формат 🔸 простой и понятный файл, удобочитаемый для человека 🔸 можно легко редактировать в любом текстовом редакторе без специальных программ и библиотек Но есть и минусы 🔹 затраты времени при записи файла (кодирование данных в нужный формат строки) 🔹 затраты времени при чтении файла (декодирование данных в Python объекты) 🔹 размер файла увеличивается из-за разметки данных (скобки, запятые, переносы, отступы...) 🔹 перед записью все данные должны быть помещены в память в полном объёме (не всегда) 🔹 при чтении необходимо считать весь файл в память и только потом декодировать данные Если нужно писать немного данных в несколько файлов, то затраты по времени не ощутимы. Обычно это файлы конфига или какие-либо метаданные. Это отличный вариант под такие задачи. Есть и другой поход к записи файлов - это бинарные файлы. Используется, когда данных достаточно много и никто их не собирается читать глазками😳. 🔸 очень быстрая запись 🔸 чтение значительно быстрей чем JSON, YAML итд 🔸 размер файла значительно меньше, так как нет разметки 🔸 можно записывать данные по мере поступления не загружая всё в память 🔸 можно извлечь любую часть данных независимо Из минусов 🔹 нужно определить свой формат записи данных (если не используете готовую спецификацию определённого формата) 🔹 не получится открыть файл и визуально понять что там записано, а для чтения файла потребуется знать его спецификацию. 🔹 не так-то просто создать такой файл без специальной библиотеки В таком виде удобно записывать большой массив любых однородных данных. Например, мониторинг валютной биржи или кэшированная анимация 3D геометрии. (Это не означает что нельзя записать данные разного типа, просто это будет не так удобно) Представьте себе JPG-картинку. По сути это немного мета-информации и большой массив пикселей. Тоже самое со звуком или видео файлом. Поэтому, если вы попробуете открыть картинку в текстовом редакторе вы увидите что-то вроде такого f15d cd29 a564 4578 ... 09e2 9bc4 a696 1253 ... 84e9 4de1 3b23 c24a ... 2534 5161 28e0 709d ... ... Это и есть записанные байтики. И для их чтения требуется определённый софт который знает что с ними делать. Под каждый тип файла. К чему это я? Читайте в следующем посте... #tricks#basic

Резултати

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

Пребарај: #gretathunberg

当前筛选 #gretathunberg清除筛选
Bloom Org

@bloomorg_uz · Post #51 · 12.06.2025 г., 14:25

#LetHerBloom #GretaThunberg ❔What happens when a climate activist speaks out on a global conflict? 💬 Greta Thunberg has always been loud - for the planet, and for the people. However when she spoke up about Palestine, the silence that followed was different… On June 9, she boarded humanitarian flotilla the Madleen, planning to deliver aid to Gaza. Israeli forces intercepted the vessel in international waters, detaining and then deporting her by June 10 - after being held in an undisclosed location and pressured to sign documents admitting illegal entry. ‼️ She is back safe, but the reality remains: Solidarity can come with heavy costs. 🌸 At Bloom, we believe speaking up and fighting is better than staying silent! So let’s fight for justice and stop traditions of staying silent in unfair situations. And again, Let Her Bloom!

Reuters: World

@reutersworldchannel · Post #149256 · 12.10.2021 г., 15:43

Greta Thunberg talks about her life Staying grounded makes coming back to normal life easier, climate activist Greta Thunberg says, as she talks about her handling of fame. #News#Reuters#GretaThunberg#lifestyle Subscribe: http://smarturl.it/reuterssubscribe Reuters brings you the latest business, finance and breaking news video from around the globe. Our reputation for accuracy and impartiality is unparalleled. Get the latest news on: http://reuters.com/ Follow Reuters on Facebook: https://www.facebook.com/Reuters Follow Reuters on Twitter: https://twitter.com/Reuters Follow Reuters on Instagram: https://www.instagram.com/reuters/?hl=en ➖@reutersworldchannel➖

Freedom Flotilla Coalition

@FFC_official_channel · Post #525 · 10.06.2025 г., 18:49

Some snippets from Greta’s interview after being deported by Israeli authorities. Continue fighting for Palestinians in Gaza, including those in wider Palestine who are unlawfully imprisoned, including over 400 children. #Madleen#IOF#GretaThunberg#FreedomFlotilla

Savino Balzano

@savinobalzano · Post #1181 · 05.10.2025 г., 17:25

https://x.com/SavinoBalzano/status/1974887738919772654 Penso davvero che #AntonioTajani rappresenti uno dei punti più bassi della storia della diplomazia italiana. Uno che va in televisione a dire che il diritto internazionale conta fino a un certo punto. Uno che parla di “abordaggi pacifici”. Uno che sottolinea come i nostri concittadini non siano stati trattati da #Israele come terroristi. A parte il fatto che mente spudoratamente: da quanto emerge, le condizioni di detenzione sono state inaccettabili e, soprattutto, gli israeliani si sono accaniti sulle persone trattenute con azioni a dir poco intollerabili. Vale però la pena ricordare, ancora una volta, che i membri della #Flottilla non stavano commettendo alcuna azione illegale. Erano in acque internazionali (acque di tutti e di nessuno) e, soprattutto, del tutto disarmati. Per quanto ci riguarda, i nostri concittadini erano anche su imbarcazioni battenti bandiera italiana, dunque su territorio della Repubblica. La stessa Repubblica di cui, purtroppo (per quanto mi riguarda), #Tajani è ministro. Ora mi rivolgo a tutti, anche agli amici di destra. Gli attivisti possono anche esservi antipatici (personalmente non ho mai nutrito alcuna simpatia per #GretaThunberg), ma non comprendere che tenere la gente in carcere illegalmente, affamarla e assetarla, costringerla a baciare la bandiera israeliana in una cella infestata dalle cimici, sia semplicemente barbaro, vi rende peggiori di chi più vi ripugna. Sia chiaro. E qualcuno ha ancora il coraggio di parlare dell’unica democrazia del Medio Oriente? Ma con che faccia? #BattitoriLiberi: dal lunedì al venerdì alle 17, su Radio Cusano

Reuters: World

@reutersworldchannel · Post #149513 · 18.10.2021 г., 14:46

Greta grooves at Stockholm climate concert Swedish climate activist Greta Thunberg surprised the crowd at the Climate Live concert in Stockholm by delivering a dance rather than a speech. #News#Reuters#GretaThunberg#Stockholm#RickAstley Subscribe: http://smarturl.it/reuterssubscribe Reuters brings you the latest business, finance and breaking news video from around the globe. Our reputation for accuracy and impartiality is unparalleled. Get the latest news on: http://reuters.com/ Follow Reuters on Facebook: https://www.facebook.com/Reuters Follow Reuters on Twitter: https://twitter.com/Reuters Follow Reuters on Instagram: https://www.instagram.com/reuters/?hl=en ➖@reutersworldchannel➖

la fionda📗

@lafionda · Post #6652 · 05.10.2025 г., 17:57

https://x.com/SavinoBalzano/status/1974887738919772654 Penso davvero che #AntonioTajani rappresenti uno dei punti più bassi della storia della diplomazia italiana. Uno che va in televisione a dire che il diritto internazionale conta fino a un certo punto. Uno che parla di “abordaggi pacifici”. Uno che sottolinea come i nostri concittadini non siano stati trattati da #Israele come terroristi. A parte il fatto che mente spudoratamente: da quanto emerge, le condizioni di detenzione sono state inaccettabili e, soprattutto, gli israeliani si sono accaniti sulle persone trattenute con azioni a dir poco intollerabili. Vale però la pena ricordare, ancora una volta, che i membri della #Flottilla non stavano commettendo alcuna azione illegale. Erano in acque internazionali (acque di tutti e di nessuno) e, soprattutto, del tutto disarmati. Per quanto ci riguarda, i nostri concittadini erano anche su imbarcazioni battenti bandiera italiana, dunque su territorio della Repubblica. La stessa Repubblica di cui, purtroppo (per quanto mi riguarda), #Tajani è ministro. Ora mi rivolgo a tutti, anche agli amici di destra. Gli attivisti possono anche esservi antipatici (personalmente non ho mai nutrito alcuna simpatia per #GretaThunberg), ma non comprendere che tenere la gente in carcere illegalmente, affamarla e assetarla, costringerla a baciare la bandiera israeliana in una cella infestata dalle cimici, sia semplicemente barbaro, vi rende peggiori di chi più vi ripugna. Sia chiaro. E qualcuno ha ancora il coraggio di parlare dell’unica democrazia del Medio Oriente? Ma con che faccia? #BattitoriLiberi: dal lunedì al venerdì alle 17, su Radio Cusano

Reuters: World

@reutersworldchannel · Post #149258 · 12.10.2021 г., 16:27

Thunberg expects 'meaningless' pledges at COP26 For activist Greta Thunberg, success at the upcoming U.N. climate conference would be possible if world leaders honestly admit that their action is not living up to their words. #GretaThunberg#COP26#UNClimateConference#ClimateChange#News#Reuters Subscribe: http://smarturl.it/reuterssubscribe Reuters brings you the latest business, finance and breaking news video from around the globe. Our reputation for accuracy and impartiality is unparalleled. Get the latest news on: http://reuters.com/ Follow Reuters on Facebook: https://www.facebook.com/Reuters Follow Reuters on Twitter: https://twitter.com/Reuters Follow Reuters on Instagram: https://www.instagram.com/reuters/?hl=en ➖@reutersworldchannel➖

Freedom Flotilla Coalition

@FFC_official_channel · Post #442 · 06.06.2025 г., 00:45

Macklemore endorses the Freedom Flotilla’s ‘Madleen’ on stage, playing a special video that Greta Thunberg recorded from the vessel. Keep all eyes on deck, and all eyes on Palestine. #GretaThunberg#Macklemore#BreakIsraelsSiege#EndTheBlockade#StandWithGaza#FreePalestine

Freedom Flotilla Coalition

@FFC_official_channel · Post #386 · 03.06.2025 г., 12:54

Listen to some of the Freedom Flotilla Coalition volunteers share why our nonviolent action is critical, just before they boarded the 'Madleen' in Catania. Keep track of our vessel and friends as they sail to Gaza via Marine Traffic or our website. Tag your Foreign Ministries to ensure that they safeguard the 'Madleen', and end their active participation in Israel's genocide and siege of Gaza. #BreakIsraelsSiege#EndTheBlockade#Madleen#FreedomFlotilla#HuwaidaArraf#GretaThunberg#DrMo#RimaHassan#YasmineAcar#ThiagoAvila