From 7c4978aac9cf74be13025f5757a693193cde1c0d Mon Sep 17 00:00:00 2001 From: Ioannis Tziakos Date: Wed, 24 Jun 2015 14:36:59 +0100 Subject: [PATCH] correct the way the HDF5 particles container is created --- simphony/bench/cuds_file_bench.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/simphony/bench/cuds_file_bench.py b/simphony/bench/cuds_file_bench.py index c800a8cf..fac6df3b 100644 --- a/simphony/bench/cuds_file_bench.py +++ b/simphony/bench/cuds_file_bench.py @@ -5,7 +5,7 @@ from simphony.bench.util import bench from simphony.io.h5_cuds import H5CUDS -from simphony.cuds.particles import Particle +from simphony.cuds.particles import Particle, Particles particles = [ Particle(coordinates=(0.0, 1.1, 2.2)) for i in range(10000)] @@ -55,8 +55,7 @@ def __init__(self): def __enter__(self): self._file = H5CUDS.open(self._filename) - pc = self._file.add_particles("test") - return pc + return self._file.add_particles(Particles("test")) def __exit__(self, type, value, tb): if os.path.exists(self._filename):