Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from pathlib import Path
- import cv2
- 以下の関数を呼び出してくると画像が開けない
- #from classfy02 import input_data
- def main():
- parent_path = Path(__file__).parent
- path = str(
- (parent_path / 'cross.png').resolve()
- )
- img = cv2.imread(path)
- cv2.namedWindow('screen', cv2.WINDOW_NORMAL)
- cv2.setWindowProperty('screen', cv2.WND_PROP_FULLSCREEN,
- cv2.WINDOW_FULLSCREEN)
- cv2.imshow('screen', img)
- cv2.waitKey(1000)
- if __name__ == '__main__':
- main()
Add Comment
Please, Sign In to add comment