how to use python to unzip file code example
Example 1: unzip in python
import zipfile
with zipfile.ZipFile(path_to_zip_file, 'r') as zip_ref:
zip_ref.extractall(directory_to_extract_to)
Example 2: unzip files python
from zipfile import ZipFile
with ZipFile(file_directory, 'r') as zip:
zip.printdir()
zip.extractall(save_directory)