import dill


def load_object_dill(filename, load_path="objects_save"):
	"""loads an object with dill (from 'objects_save/' directory)
	
	:param filename: filename without any extension
	:param load_path: path where to load object from, staring from the directory of the simulation (default "objects_save")
	:returns: saved object"""
	# unpickling
	f = open(load_path+"/"+filename+'.pickle', 'rb')	
	obj = dill.load(f)
	f.close()
	return obj