파이썬 파일 사이즈 확인하는 방법
os.path.getsize()를 사용하여 파일 용량(bytes) 확인 가능
import os
path = '파일 경로'
os.path.getsize(path)
https://docs.python.org/3/library/os.path.html#os.path.getsize
os.path — Common pathname manipulations — Python 3.8.1rc1 documentation
os.path — Common pathname manipulations Source code: Lib/posixpath.py (for POSIX) and Lib/ntpath.py (for Windows NT). This module implements some useful functions on pathnames. To read or write files see open(), and for accessing the filesystem see the os
docs.python.org
'개발언어 > Python' 카테고리의 다른 글
Python Transmission RPC 문서 (0) | 2019.12.15 |
---|