diff --git a/physbo/search/discrete/results.py b/physbo/search/discrete/results.py index f925830b..75651989 100644 --- a/physbo/search/discrete/results.py +++ b/physbo/search/discrete/results.py @@ -183,8 +183,8 @@ def load(self, filename): """ data = np.load(filename) - M = data["num_runs"] - N = data["total_num_search"] + M = int(data["num_runs"]) + N = int(data["total_num_search"]) self.num_runs = M self.total_num_search = N self.fx[0:N] = data["fx"] diff --git a/physbo/search/discrete_multi/results.py b/physbo/search/discrete_multi/results.py index 96288a86..c711fd42 100644 --- a/physbo/search/discrete_multi/results.py +++ b/physbo/search/discrete_multi/results.py @@ -118,8 +118,8 @@ def load(self, filename): with open(filename, "rb") as f: data = pickle.load(f) - M = data["num_runs"] - N = data["total_num_search"] + M = int(data["num_runs"]) + N = int(data["total_num_search"]) self.num_runs = M self.total_num_search = N self.fx[0:N] = data["fx"]