实例代码:
import tkinter as tk
import tkinter.filedialog
import cv2
def choose_file(): # 选择文件
selectFileName = tk.filedialog.askopenfilename(title='\u9009\u62e9\u6587\u4ef6')
e.set(selectFileName)
def show(e_entry): #显示图片
img = cv2.imread(e_entry.get())
cv2.imshow("PICTURE",img)
cv2.waitKey(0)
def window():
ro
1