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

Резултати

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

Пребарај: #gaza

当前筛选 #gaza清除筛选
RT en français

@RTenfrancais · Post #80793 · 04.05.2026 г., 10:20

🖼Gaza : soutien pictural ▪️Dans la bande de #Gaza, des artistes ont réalisé des fresques murales pour exprimer leur soutien à la flottille internationale Global Sumud. Crédit vidéo : Agence Anadolu RT en français • Osez questionner !

Hashtags

RT en français

@RTenfrancais · Post #80722 · 03.05.2026 г., 11:00

⏺À #Gaza, des mariés ont opté pour un moyen de transport inédit : une pelleteuse Le couple a traversé les rues, malgré les décombres témoignant de la destruction générale dont elles ont été le théâtre. Source : réseaux sociaux RT en français • Osez questionner !

Hashtags

🎥 Lа Prимиcя

@la_primicia · Post #71318 · 23.04.2026 г., 01:02

🫦 Algunas personas podrían encontrar perturbadoras las imágenes y videos compartidos. Se recomienda discreción. ⚠️🤔🏴‍☠️⚔️🇵🇸 Imágenes de la horrible masacre perpetrada por las fuerzas de ocupación contra un grupo de ciudadanos en el barrio de Beit Lahia, al norte de #Gaza.

Hashtags

Resistance News Network Backup

@RNN_Backup · Post #64825 · 25.10.2024 г., 14:45

🚨 The IOF carried out a new massacre, destroying an entire residential block above the heads of citizens on Tal Al-Zaatar in Jabalia, northern #Gaza Strip. Two martyrs have been recovered so far and there are a large amount of wounded. Artillery shelling continues on various parts of Jabalia, and several martyrs have ascended there as a result of residential homes being targeted. 4 martyrs and 5 injuries were reported as a result of the IOF targeting of a gathering of citizens on Al-Nasr Street west of Gaza City. Further, internet and communications have been cut off in the northern Gaza Strip as a result of the IOF aggression, as the siege enters its third week.

Hashtags

Resistance News Network Backup

@RNN_Backup · Post #64785 · 25.10.2024 г., 14:20

🚨🟢 BREAKING - Hamas leader Khalil Al-Hayya announces the martyrdom of the great leader, President of the Hamas Political Bureau, the hero of Al-Aqsa Flood, Yahya Sinwar, who sought martyrdom and attained it after clashing with a zionist force alongside other fighters in the #Gaza Strip. Further coverage of the Al-Hayya’s statement will be provided. Glory to the martyrs.

Hashtags

Resistance News Network Backup

@RNN_Backup · Post #64735 · 25.10.2024 г., 13:39

Ahmed Al-Telbani, Director of the Central Station in the Medical Services’ Emergency and Ambulance Department, ascended to martyrdom along with his family members in the IOF air strike of their home in Maghazi camp, central #Gaza Strip. Glory to the martyrs.

Hashtags

Resistance News Network Backup

@RNN_Backup · Post #64733 · 25.10.2024 г., 13:37

🔻 The IOF admits to the death of 5 IOF soldiers, including two officers, during a battle with the resistance in southern Lebanon. In the same incident, three Golani Brigade soldiers (including an officer) were seriously wounded. In total, the IOF admitted to the critical wounding of 8 zionist soldiers in three battles in southern Lebanon. They also admitted to the serious wounding of a soldier during a battle in the southern #Gaza Strip yesterday.

Hashtags

Resistance News Network Backup

@RNN_Backup · Post #64705 · 25.10.2024 г., 13:11

🚨 10 martyrs have been recovered by Civil Defense crews following the IOF bombing the Al-Telbani family home in Maghazi camp in the central #Gaza Strip. 60 martyrs have ascended in the Gaza Strip today, with at least 25 of them in Jabalia camp.

Hashtags

Resistance News Network Backup

@RNN_Backup · Post #64698 · 25.10.2024 г., 13:09

On October 17th, 2023, in a cowardly assassination, commander Ayman Nofal ascended after US-funded IOF warplanes targeted him in Bureij camp in central #Gaza. Beloved by allfactions, the commanding martyr was an Al-Qassam Brigades leader who created the foundations of the united Joint Operations Room of Palestinian Resistance Factions, a room in which the spectrum of Palestinian and Arab resistance coordinate. Just weeks ago, Ayman's nephew was martyred at the Gaza border protests. Ayman embodied the spirit of the Joint Room which he led in his words and deeds, recognizing, like martyred leaders before him, "Either we rise together, or they will kill us individually." Here, Ayman speaks in 2021 at the Joint Operation's Room annual training for all factions. Without a doubt, Ayman was one of the engineers of the long-planned Al-Aqsa Flood for the sake of our prisoners and Al-Aqsa, evident in the words of this speech: GiladShalit was just practice. Learning from the lessons of previous operations and honoring the blood of the martyrs, we march forth towards liberation, never forgetting those who paved the path. Glory to our martyrs! Glory to our resistance! Liberation nears with their guiding illumination.

Hashtags

Resistance News Network Backup

@RNN_Backup · Post #64674 · 25.10.2024 г., 12:52

🚨 22 martyrs have ascended in the horrific massacre at the Abu Hussein School in Jabalia camp, northern #Gaza Strip, and dozens are wounded. Most of the martyrs are children and women, after the IOF bombed the school housing a large number of displaced people. Tanks began firing shells at the school after advancing from west of Jabalia. The hospitals in the north are unable to deal with the large number of injuries and martyrs. The IOF also bombed the Khalifa School in the northern #Gaza Strip, resulting in a large fire and one martyr. In a series of strikes, at least 11 martyrs ascended in Gaza City. The siege of Jabalia camp and the north continues for the 13th day without any aid reaching it.

Hashtags

123•••5•••10•••15•••20•••25•••30•••35•••40•••45•••5051
ПретходнаСтраница 1 од 51Следна