Commit f49a8ab6 authored by Moritz's avatar Moritz

deepcopying PriorDicts does not work in python 2

parent 36339603
......@@ -2,7 +2,7 @@ from __future__ import division
import os
from collections import OrderedDict, namedtuple
from copy import deepcopy
from copy import copy
from distutils.version import LooseVersion
from itertools import product
......@@ -1230,13 +1230,12 @@ class ResultList(list):
Return the combined results in a :class:bilby.core.result.Result`
object.
"""
if len(self) == 0:
return Result()
elif len(self) == 1:
return deepcopy(self[0])
return copy(self[0])
else:
result = deepcopy(self[0])
result = copy(self[0])
if result.label is not None:
result.label += 'combined'
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment