def get_file(x, ftp_dir, conn):
    if not os.path.exists(x):
        print "Retrieving %s" % x
        with open(x, "wb") as out_handle:
            conn = ftplib.FTP(FTP, "anonymous", "me@example.com")
            conn.cwd(ftp_dir)
            conn.retrbinary("RETR %s" % x, out_handle.write)
    return x
dataset/ETHPy150Open chapmanb/cloudbiolinux/utils/prepare_dbsnp.py/get_file/original