Python之GUI:基于Python的GUI界面设计的一套AI课程学习(机器学习、深度学习、大数据、云计算等)推荐系统(包括语音生成、识别等前沿黑科技)

简介: Python之GUI:基于Python的GUI界面设计的一套AI课程学习(机器学习、深度学习、大数据、云计算等)推荐系统(包括语音生成、识别等前沿黑科技)

输出结果

https://img-blog.csdn.net/20180529114418537

image.png

image.png

核心代码

def niu_read_docx(filename):

    doc=docx.Document(filename)

    fulltext=[]

    for para in doc.paragraphs:

        fulltext.append(para.text)

    return '\n'.join(fulltext)

class dialog(QDialog, Ui_dialog):

   """

   Class documentation goes here.

   """

   def __init__(self, parent=None):

       """

       Constructor

     

       @param parent reference to the parent widget

       @type QWidget

       """

       super(dialog, self).__init__(parent)

       self.setupUi(self)

     

       time.sleep(2) #使开机画面停留2秒

 

   @pyqtSlot()

   def on_pushButton_clicked(self):

       """

       Slot documentation goes here.

       """

       my_str_2=self.lineEdit_2.text()

       my_str_3=self.lineEdit_3.text()

       my_str_4=self.lineEdit_4.text()

     

       print(my_str, my_str_2, my_str_3, my_str_4)

       Button1_1=QMessageBox.information(self, u'提示信息框', u'输入的s所有信息已经存储到数据库中!', ) #提示对话信息框

       print('OK')

       self.close() #关闭当前界面

 

   @pyqtSlot()

   def on_pushButton_2_clicked(self):

       """

       Slot documentation goes here.

       """

       print('Cancel')

class MainWindow(QMainWindow, Ui_MainWindow):

   """

   Class documentation goes here.

   """

   def __init__(self, parent=None):

       """

       Constructor

       @param parent reference to the parent widget

       @type QWidget

       """

       super(MainWindow, self).__init__(parent)

       self.setupUi(self)

       self.graphicsView.mousePressEvent=self.my_clicked

     

   def my_clicked(self, e):

       print('自定义的点击事件函数')

       webbrowser.open('www.baidu.com') #默认浏览器打开指定网址

   @pyqtSlot()

   def on_pushButton_clicked(self):

       """

       Slot documentation goes here.

       """

       print(self.textBrowser.toPlainText())

 

   @pyqtSlot()

   def on_pushButton_2_clicked(self):

       """

       Slot documentation goes here.

       这是测试按钮的槽函数

       """

       self.lineEdit.setText( "")  #清除单行文本框内容

       self.lineEdit_2.setText( "")

       self.textBrowser.setText( "") #清除多行文本框内容

       print("清除登陆账号信息!")

 

   @pyqtSlot()

   def on_pushButton_3_clicked(self):

       """

       Slot documentation goes here.

       """

       my_str=self.lineEdit.text()+":"+self.lineEdit_2.text() #获取单行文本框的内容

       self.textBrowser.append(my_str) #向多行文本添加内容

       print(my_str)

     

   @pyqtSlot()

   def on_pushButton_4_clicked(self):

       """

       Slot documentation goes here.

       该按钮命令调用的预定义的函数,退出的命令

       """

   @pyqtSlot()

   def on_pushButton_5_clicked(self):

       """

       Slot documentation goes here.

       """

       Button5=QMessageBox.question(self, u'提示信息框', u'是否全部保存到数据库中?')

       if Button5==0:

           print('全部保存中……')

       else:

           print('没有保存')

         

     

   @pyqtSlot()

   def on_pushButton_6_clicked(self):

       """

       Slot documentation goes here.

       """

       Button6=QMessageBox.warning(self, u'提警告信息框', u'没有警告信息,请继续输入!')

     

   @pyqtSlot()

   def on_pushButton_7_clicked(self):

       """

       Slot documentation goes here.

       """

       Button7=QMessageBox.critical(self, u'严重警告!', u'没有严重警告信息,请继续输入!')

 

   @pyqtSlot()

   def on_pushButton_9_clicked(self):

       """

       Slot documentation goes here.

       """

       self.graphicsView.setStyleSheet("border-image: url(:/im/image/AI (4).jpg);")

     

     

#    @pyqtSlot(QUrl)

   def on_textBrowser_anchorClicked(self, p0):

       """

       Slot documentation goes here.

     

       @param p0 DESCRIPTION

       @type QUrl

       """

   @pyqtSlot()

   def on_radioButton_clicked(self):

       """

       Slot documentation goes here.

       """

       print('同时选择其他三个首个radioButton')

       self.radioButton_12.setChecked(True)

       self.radioButton_16.setChecked(True)

       self.radioButton_20.setChecked(True)

       self.label_4.setStyleSheet("border-image: url(:/im/image/AI (4).jpg);")


相关实践学习
基于MaxCompute的热门话题分析
Apsara Clouder大数据专项技能认证配套课程:基于MaxCompute的热门话题分析
相关文章
|
SQL 人工智能 分布式计算
ODPS十五周年实录|构建 AI 时代的大数据基础设施
本文根据 ODPS 十五周年·年度升级发布实录整理而成,演讲信息如下: 张治国:阿里云智能集团技术研究员、阿里云智能计算平台事业部 ODPS-MaxCompute 负责人 活动:【数据进化·AI 启航】ODPS 年度升级发布
615 9
|
存储 人工智能 安全
拔俗AI临床大数据科研分析平台:让医学研究更智能、更高效
阿里云原生AI临床大数据科研平台,打通异构医疗数据壁垒,实现智能治理、可视化分析与多中心安全协作,助力医院科研提速增效,推动精准医疗发展。
1894 1
|
人工智能 Cloud Native 算法
拔俗云原生 AI 临床大数据平台:赋能医学科研的开发者实践
AI临床大数据科研平台依托阿里云、腾讯云,打通医疗数据孤岛,提供从数据治理到模型落地的全链路支持。通过联邦学习、弹性算力与安全合规技术,实现跨机构协作与高效训练,助力开发者提升科研效率,推动医学AI创新落地。(238字)
773 7
|
数据采集 传感器 人工智能
没有大数据,哪来人工智能?——聊聊“大数据喂养下的AI进化史”
没有大数据,哪来人工智能?——聊聊“大数据喂养下的AI进化史”
566 6
|
人工智能 分布式计算 DataWorks
阿里云大数据AI产品月刊-2025年8月
阿里云大数据& AI 产品技术月刊【2025年 8 月】,涵盖 8 月技术速递、产品和功能发布、市场和客户应用实践等内容,帮助您快速了解阿里云大数据& AI 方面最新动态。
900 2
|
传感器 人工智能 监控
拔俗多模态跨尺度大数据AI分析平台:让复杂数据“开口说话”的智能引擎
在数字化时代,多模态跨尺度大数据AI分析平台应运而生,打破数据孤岛,融合图像、文本、视频等多源信息,贯通微观与宏观尺度,实现智能诊断、预测与决策,广泛应用于医疗、制造、金融等领域,推动AI从“看懂”到“会思考”的跃迁。
923 0
|
人工智能 大数据 安全
拔俗AI临床大数据科研分析平台:用智能技术加速医学研究新突破
AI临床大数据科研平台基于云原生架构,融合医疗NLP、联邦学习与智能分析技术,破解非结构化数据处理难、多源数据融合难、统计周期长等痛点,实现数据治理、智能分析与安全协作全链路升级,赋能医学科研高效、安全、智能化发展。
543 0
|
机器学习/深度学习 搜索推荐 算法
基于python大数据的口红商品分析与推荐系统
本研究基于Python大数据技术,构建口红商品分析与推荐系统,旨在解决口红市场产品同质化与消费者选择困难问题。通过分析颜色、质地、价格等多维度数据及用户行为,实现个性化推荐,提升购物体验与品牌营销效率,推动美妆行业数字化转型,具有重要现实意义与市场价值。

推荐镜像

更多