Commit 91e81b8a authored by David Hendriks's avatar David Hendriks
Browse files

Fixed merge_dict for ordererddicts

parent 8a7a65c5
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -1497,6 +1497,11 @@ def merge_dicts(dict_1: dict, dict_2: dict) -> dict:
                type(dict_2[key]) in [int, float, np.float64]
            ):
                new_dict[key] = dict_1[key] + dict_2[key]
            # Exceptions:
            elif (type(dict_1[key]) in [dict, OrderedDict]) and (
                type(dict_2[key]) in [dict, OrderedDict]
            ):
                new_dict[key] = merge_dicts(dict_1[key], dict_2[key])

            else:
                print(
+0 −1
Original line number Diff line number Diff line
@@ -943,7 +943,6 @@ class Population:
        # Put back in the dictionary
        return reformatted_ensemble_results


    def _evolve_population_grid(self):
        """
        Function to evolve the population with multiprocessing approach.