HandWriteRecognition.py 文件源码

python
阅读 28 收藏 0 点赞 0 评论 0

项目:pyqt5 作者: yurisnm 项目源码 文件源码
def openFilePressed(self):
        self._path = self._fileDialog.\
            getOpenFileName(self, "Image Files (*.png *.jpg)")
        if self._path[0] != "":
            self._pixmap = QPixmap(self._path[0])
            size = QSize(160, 90)
            pix = self._pixmap.scaled(size,
                                      transformMode=Qt.SmoothTransformation)
            self._lbl.setPixmap(pix)
            self._image = Image.open(self._path[0])
            text = pytesseract.image_to_string(self._image)
            self._line.setText(text)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号