Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MPI並列時にpolicyのloadに失敗する #60

Open
aoymt opened this issue Aug 27, 2024 · 0 comments
Open

MPI並列時にpolicyのloadに失敗する #60

aoymt opened this issue Aug 27, 2024 · 0 comments

Comments

@aoymt
Copy link

aoymt commented Aug 27, 2024

MPI並列で実行する際に、save で保存した policy を load すると、以下のエラーが出ます。

Traceback (most recent call last):
File "/home/user/work/physbo/work/tutorial3_mpi/run4b.py", line 41, in
policy.load(file_history='history.npz', file_training='training.npz', file_predictor='predictor.dump')
File "/home/user/.conda/envs/py39-physbo/lib/python3.9/site-packages/physbo/search/discrete/policy.py", line 697, in load
self.actions = self._delete_actions(self.history.chosen_actions[:N])
File "/home/user/.conda/envs/py39-physbo/lib/python3.9/site-packages/physbo/search/discrete/policy.py", line 798, in _delete_actions
return np.delete(actions, index)
File "/home/user/.conda/envs/py39-physbo/lib/python3.9/site-packages/numpy/lib/function_base.py", line 5353, in delete
keep[obj,] = False
IndexError: index 9395 is out of bounds for axis 0 with size 5001

読み込み時に、action のリストから既に評価済みの候補を除外する箇所ですが、
リストが分割されている場合に index のエラーになるようです。
修正案を添付します。

patch.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant