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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #175 · 30 окт.

В прошлом посте говоря "Все вызовы теперь одинаковы" я несколько слукавил. Всё-таки есть в этом зоопарке версий некоторая несовместимость вызов которой просто так не унифицировать. Эти моменты вынесены в отдельный модуль QtCompat (compatibility). Там не так много функций но они довольно полезны. Этот модуль содержит унификаци модуля shiboken2, функций loadUi, translate и несколько переименованных функций классов или изменённую сигнатуру аргументов и возвращаемых значений. Это единственное исключение из правила когда вам потребуется где-то изменить свой код кроме импортов и этот код не похож на обычный код PySide2. Например, в PyQt4 и PySide есть метод QHeaderView.setResizeMode Для PyQt5 и PySide2 они были благополучно переименованы в QHeaderView.setSectionResizeMode Чтобы применить этот метод следует использовать такой код from Qt import QtCompath header = self.horizontalHeader() QtCompat.QHeaderView.setSectionResizeMode(header, QtWidgets.QHeaderView.Fixed) Унификация загрузки UI файлов: # PySide2 from PySide2.QtUiTools import QUiLoader loader = QUiLoader() widget = loader.load(ui_file) # PyQt5 from PyQt5 import uic widget = uic.loadUi(ui_file) # Qt.py from Qt import QtCompat widget = QtCompat.loadUi(ui_file) Хорошо что таких моментов не много и их легко запомнить. Полный список можно посмотреть в таблице. #qt#tricks

Hashtags

Резултати

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

Пребарај: #techrace

当前筛选 #techrace清除筛选
AI & Law

@ai_and_law · Post #62 · 20.07.2023 г., 07:04

Europe's AI Battle: France vs. UK in the Race for Supremacy Hello AI enthusiasts! It seems like French President Emmanuel Macron and British Prime Minister Rishi Sunak are locking horns to claim the throne of AI dominance in Europe. 🔹The Race for Funds: Macron announced a whopping €500 million investment to create new AI champions in France, on top of previous commitments. Meanwhile, the U.K. government pledged £1 billion for supercomputing and AI research to become a "science and technology superpower." 🔹 Regulation Approaches: France falls under the jurisdiction of the EU's AI Act, focusing on risk assessment and banning certain AI applications. On the other hand, the U.K. takes a principles-based approach, advising industry regulators on enforcing existing rules flexibly and pro-innovation. 🔹 Who Will Reign Supreme? Experts are divided. France has access to talent and startups, but the EU AI Act may pose challenges. The U.K.'s approach prioritizes investment, but concerns about political uncertainties remain. 🌍 Collaboration for Success: While the competition heats up, industry leaders emphasize the need for European tech hubs to join forces, fostering collaboration and investing in a robust ecosystem to challenge U.S. AI giants. Who will emerge victorious and claim the crown of Europe's AI champion? #AIChampions#AIRegulations#TechRace#AI