importminerlimportminerl.dataimportosif__name__=="__main__":data_dir=os.getenv('MINERL_DATA_ROOT','data')data_dir='data'ifnotdata_direlsedata_dirprint("Verifying (and downloading) MineRL dataset..\n""\t**If you do not want to use the data**:\n\t\t run the local evaluation scripts with `--no-data`\n""\t**If you want to use your existing download of the data**:\n ""\t\tmake sure your MINERL_DATA_ROOT is set.\n\n")print("Data directory is {}".format(data_dir))should_download=Truetry:data=minerl.data.make('MineRLObtainDiamondVectorObf-v0',data_dir=data_dir)assertlen(data._get_all_valid_recordings(data.data_dir))>0should_download=FalseexceptFileNotFoundError:print("The data directory does not exist in your submission, are you running this script from"" the root of the repository? data_dir={}".format(data_dir))exceptRuntimeError:print("The data contained in your data directory is out of date! data_dir={}".format(data_dir))exceptAssertionError:print("No MineRLObtainDiamond-v0 data found. Did the data really download correctly?")ifshould_download:print("Attempting to download the dataset...")minerl.data.download(data_dir)print("Data verified! A+!")