import pathlib
from pathlib import Path
def create_folder(path):
if Path(path).is_dir():
print ("Folder already exists!")
else:
pathlib.Path(path).mkdir(parents=True, exist_ok=True)
print ("Folder created!")
FOLDER_PATH = '/content/drive/MyDrive/detect-covid19-xray/data-preprocessed'
create_folder(FOLDER_PATH)
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter