def fetch_nb_dependencies(files, repo=REPO, raw=RAW, branch=BRANCH, deps=DEPS, overwrite=False, verbose=True):

    #-Generate Common Data Structure-#
    if type(files) == list:
        files = {"" : files}

    #-Obtain each requested file-#
    for directory in files.keys():
        if directory != "":
            if verbose: print("Parsing directory: %s")
        for fl in files[directory]:
            if directory != "":
                fl = directory+"/"+fl
            #-Check for Local Copy of File (Default Behaviour is to Skip)-#
            if not overwrite:
                if os.path.isfile(fl):
                    if verbose: print("A file named %s already exists in the specified directory ... skipping download."%fl)
                    continue
            else:
                if verbose: print("Overwriting file %s ..."%fl)
            if verbose: print("Fetching file: %s"%fl)
            #-Get file in OS agnostic way using requests-#
            url = "/".join([repo,raw,branch,deps,fl])
            r = requests.get(url)
            with open(fl, "wb") as fl:
                fl.write(r.content)
Retrieve raw files from QuantEcon.notebooks or any other Github repo
dataset/ETHPy150Open QuantEcon/QuantEcon.py/quantecon/util/notebooks.py/fetch_nb_dependencies