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

Резултати

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

Пребарај: #chavismo

当前筛选 #chavismo清除筛选
Venezuelanalysis

@venanalysis · Post #1703 · 31.07.2024 г., 03:18

The Venezuelanalysis team held a livestream on Tuesday evening to provide an on-the-ground update of the situation in Venezuela following Sunday's elections. Watch the video: https://venezuelanalysis.com/video/venezuelas-post-election-scene-on-the-ground-reports/ #Venezuela#Chavismo#Elections2024

Venezuelanalysis

@venanalysis · Post #2063 · 13.08.2025 г., 16:38

📰 NEWS | Venezuelans Reject US Military Threats, ‘Narcoterrorism’ Allegations in Anti-Imperialist March Thousands joined the 'Great Anti-Imperialist March' in Caracas and other cities to reject US threats and the $50M bounty on President Maduro. The Trump administration accuses Maduro of ties to criminal groups, but has provided no court-tested evidence. Mexico’s President Claudia Sheinbaum said her government has 'no proof' of such links, while Colombia’s President Gustavo Petro condemned possible US military action in Latin America. 🔗 Read the full report here: https://shorturl.at/IlELJ #AntiImperialism#Chavismo#NicolasMaduro

Venezuelanalysis

@venanalysis · Post #2315 · 25.03.2026 г., 00:06

🖊OPINION | Venezuela: Between Imperial Intervention and Class Suicide Joan López and Alejandro Pedregal analyze Venezuela's post-January 3 setbacks and the broader implications for the anti-imperialist struggle. On January 3, 2026, a US military operation in Caracas resulted in the abduction of Nicolás Maduro and more than 90 deaths. In the weeks that followed, Venezuelan authorities advanced a reform of the hydrocarbon law allowing foreign companies to directly market oil production and ending the state monopoly on exports. The reform “eliminates any remaining obstacles to private operational control of that sector.” This opinion piece links these developments to shifts in economic policy and foreign relations following the change in leadership. Full piece here 👉🏽https://shorturl.at/CniyW #2026OilReform#Chavismo#Sanctions#USVenezuelaRelations

Venezuelanalysis

@venanalysis · Post #2371 · 18.05.2026 г., 20:58

🖊OPINION | The Post-January 3 Minefield in Venezuela What comes after January 3 in Venezuela? VA columnist Clodovaldo Hernández examines the political tensions shaping Venezuela after the US military attack, the kidnapping of President Nicolás Maduro and First Lady Cilia Flores, and the concessions and debates that have followed inside Chavismo and the opposition. “The controversy surrounding this issue lies dormant beneath the surface, like a geological fault line that became active following the bombing.” The piece looks at internal disagreements over reforms, sanctions, reconciliation efforts, and the evolving role of opposition sectors in the current political landscape. Read more here 👉https://shorturl.at/eOGkp #Chavismo#USVenezuelaRelations#Opposition#UnusualandExtraordinary

Venezuelanalysis

@venanalysis · Post #2040 · 26.07.2025 г., 15:29

📷 NEWS | Chavismo and Opposition Urge Voters to Participate in Final Campaign Push Ahead of Municipal Elections On Sunday, Venezuelans will elect 335 mayors and 2,471 municipal councillors. The vote marks the culmination of Venezuela’s electoral cycle, following last year’s presidential election and the recent legislative and regional races, both of which yielded favourable outcomes for the ruling United Socialist Party (PSUV) and allied organizations. Chavismo and opposition candidates wrapped up the 14-day campaign on Thursday with large rallies nationwide. Currently, two-thirds of the country's 335 municipalities are under Socialist control, while opposition factions hold over 100 mayoralties. Read our report (+photos): https://venezuelanalysis.com/images/chavismo-and-opposition-urge-voters-to-participate-in-final-campaign-push-ahead-of-municipal-elections/ #MunicipalElections#Chavismo#Opposition#Venezuela

Venezuelanalysis

@venanalysis · Post #2328 · 07.04.2026 г., 17:59

🗒️🗣️ INTERVIEW | Reinaldo Iturriza: ‘The Priority Is to Organize the Counter-Offensive’ Reinaldo Iturriza analyzes the present Venezuelan political context, the US attacks, and the strategic setbacks for the Bolivarian Process. He describes the January 3 events as “an invasion, in every sense of the word,” linking US actions to control over strategic resources such as oil, and stresses that “the priority must be on organizing the counter-offensive,” arguing that this requires rebuilding political organization and uniting forces to recover national sovereignty. Read the full interview here 👉🏾https://venezuelanalysis.com/interviews/reinaldo-iturriza-the-priority-is-to-organize-the-counter-offensive/ #Chavismo#USmilitaryattack#USVenezuelaRelations#DiarioRed

Marx21.it

@marx21news · Post #9546 · 12.01.2026 г., 15:59

Caracas sotto attacco: Delcy Rodríguez al centro della resistenza L’aggressione militare degli Stati Uniti e il sequestro del Presidente Nicolás Maduro non sono episodi isolati: fanno parte di una strategia globale di pressione contro la Rivoluzione Bolivariana. In questo momento cruciale, la Vicepresidente Delcy Rodríguez garantisce la continuità dello Stato, difende la legittimità costituzionale e contrasta la propaganda che cerca di dividere il PSUV. Come ha affermato: «Qui c’è un solo Presidente, e si chiama Nicolás Maduro Moros». Una frase che non è solo politica: è un argine contro il caos, la disinformazione e le pressioni esterne. Il chavismo resta un blocco politico solido, con istituzioni funzionanti, popolo organizzato e forze armate unite. La strategia di destabilizzazione esterna non passerà. #Venezuela#Chavismo#DelcyRodríguez#Sovranità#Maduro#Unità https://www.marx21.it/internazionale/caracas-sotto-attacco-psuv-sotto-pressione-delcy-rodriguez-nel-mirino-della-guerra-ibrida-contro-il-venezuela/

Venezuelanalysis

@venanalysis · Post #1512 · 27.03.2024 г., 23:26

Sociologist Reinaldo Iturriza delves into the phenomenon of “disaffiliation” in present-day Venezuela. "Political disaffiliation is what happens when a sector of the forces that identified with a certain project no longer recognizes itself in the present course of affairs or does not agree with the reorientation given by those exercising leadership roles. The disaffiliated individual is not willing to adopt what they interpret as a different course from the one that drove their identification with the project, and therefore can no longer see themselves in those who represent, so to speak, the political identity. Does the above imply a renunciation to the project, and even to its political identity? Absolutely not when it comes to the project, and not necessarily when it comes to political identity." Learn more here: https://shorturl.at/gELOU #politics#Politicaldisaffiliation#Venezuela#Chavismo#elections