ray.init抛出列表索引超出范围错误

问题描述

我正在使用ID Gene Tier Consequence 1314 ABC TIER1 missense 1314 PKD1 TIER1 frameshift 6245 BJD TIER1 splice_site_variant 7631 PKD2 TIER1 missense 5336 PKD1 TIER3 missense 1399 PKD1 TIER2 non-coding 版。运行0.8.6时,在connect的{​​{1}}函数中发生错误。我能够跟踪该错误,并且发生在以下部分。

worker.py

ray.init()行假定if mode == SCRIPT_MODE: # Add the directory containing the script that is running to the Python # paths of the workers. Also add the current directory. Note that this # assumes that the directory structures on the machines in the clusters # are the same. script_directory = os.path.abspath(os.path.dirname(sys.argv[0])) current_directory = os.path.abspath(os.path.curdir) worker.run_function_on_all_workers( lambda worker_info: sys.path.insert(1,script_directory)) worker.run_function_on_all_workers( lambda worker_info: sys.path.insert(1,current_directory)) # Todo(rkn): Here we first export functions to run,then remote # functions. The order matters. For example,one of the functions to # run may set the Python path,which is needed to import a module used # to define a remote function. We may want to change the order to # simply be the order in which the exports were defined on the driver. # In addition,we will need to retain the ability to decide what the # first few exports are (mostly to set the Python path). Additionally,# note that the first exports to be defined on the driver will be the # ones defined in separate modules that are imported by the driver. # Export cached functions_to_run. for function in worker.cached_functions_to_run: worker.run_function_on_all_workers(function) worker.cached_functions_to_run = None 必须为非空,但在我的情况下为空。 我禁用了将script_directory = os.path.abspath(os.path.dirname(sys.argv[0]))复制到工作人员的功能,看来一切正常。正确的进行方式应该是什么?

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)