Merge remote-tracking branch 'upstream/develop' into iso-lab

This commit is contained in:
Will Boyd 2015-06-09 22:10:51 -07:00
commit 3b2959e8ca
104 changed files with 350 additions and 266 deletions

View file

@ -651,7 +651,7 @@ class Tally(object):
Raises
------
KeyError : An error when the argument passed to the 'nuclide'
KeyError : An error when the argument passed to the 'nuclide'
parameter cannot be found in the Tally.
"""
@ -694,7 +694,7 @@ class Tally(object):
Raises
------
ValueError: An error when the argument passed to the 'score'
ValueError: An error when the argument passed to the 'score'
parameter cannot be found in the Tally.
"""
@ -816,7 +816,7 @@ class Tally(object):
self.get_filter_index(filter.type, bin))
# Apply cross-product sum between all filter bin indices
filter_indices = map(sum, itertools.product(*filter_indices))
filter_indices = list(map(sum, itertools.product(*filter_indices)))
# If user did not specify any specific Filters, use them all
else:
@ -874,7 +874,7 @@ class Tally(object):
This routine constructs a Pandas DataFrame object for the Tally data
with columns annotated by filter, nuclide and score bin information.
This capability has been tested for Pandas >=v0.13.1. However, if p
possible, it is recommended to use the v0.16 or newer versions of
possible, it is recommended to use the v0.16 or newer versions of
Pandas since this this routine uses the Multi-index Pandas feature.
Parameters
@ -951,7 +951,7 @@ class Tally(object):
# Append Mesh ID as outermost index of mult-index
mesh_id = filter.mesh.id
mesh_key = 'mesh {0}'.format(mesh_id)
mesh_key = 'mesh {0}'.format(mesh_id)
# Find mesh dimensions - use 3D indices for simplicity
if (len(filter.mesh.dimension) == 3):
@ -1013,8 +1013,8 @@ class Tally(object):
# offsets to OpenCG LocalCoords linked lists
offsets_to_coords = {}
# Use OpenCG to compute LocalCoords linked list for
# each region and store in dictionary
# Use OpenCG to compute LocalCoords linked list for
# each region and store in dictionary
for region in range(num_regions):
coords = opencg_geometry.findRegion(region)
path = opencg.get_path(coords)
@ -1023,7 +1023,7 @@ class Tally(object):
# If this region is in Cell corresponding to the
# distribcell filter bin, store it in dictionary
if cell_id == filter.bins[0]:
offset = openmc_geometry.get_offset(path,
offset = openmc_geometry.get_offset(path,
filter.offset)
offsets_to_coords[offset] = coords
@ -1053,7 +1053,7 @@ class Tally(object):
lat_y_key = (level_key, 'lat', 'y')
lat_z_key = (level_key, 'lat', 'z')
# Allocate NumPy arrays for each CSG level and
# Allocate NumPy arrays for each CSG level and
# each Multi-index column in the DataFrame
level_dict[univ_key] = np.empty(num_offsets)
level_dict[cell_key] = np.empty(num_offsets)
@ -1113,9 +1113,9 @@ class Tally(object):
tile_factor = data_size / len(level_bins)
level_bins = np.tile(level_bins, tile_factor)
level_dict[level_key] = level_bins
# Append the multi-index column to the DataFrame
df = pd.concat([df, pd.DataFrame(level_dict)],
df = pd.concat([df, pd.DataFrame(level_dict)],
axis=1)
# Create DataFrame column for distribcell instances IDs
@ -1132,7 +1132,7 @@ class Tally(object):
bins = filter.bins
num_bins = filter.num_bins
# Create strings for
# Create strings for
template = '{0:.1e} - {1:.1e}'
filter_bins = []
for i in range(num_bins):

View file

@ -44,12 +44,12 @@ def main():
if not (fname.endswith('.h5') or fname.endswith('.binary')):
raise ValueError("Input file names must either end with '.h5' or"
"'.binary'.")
# Make sure that the output filename ends with '.pvtp'.
if not args.out:
args.out = 'tracks.pvtp'
elif os.path.splitext(args.out)[1] != '.pvtp':
args.out = ''.join([args.out, '.pvtp'])
elif not args.out.endswith('.pvtp'):
args.out += '.pvtp'
# Import HDF library if HDF files are present
for fname in args.input:
@ -74,26 +74,28 @@ def main():
coords = h5py.File(fname).get('coordinates')
n_points = coords.shape[0]
for i in range(n_points):
points.InsertNextPoint(coords[i,:])
points.InsertNextPoint(coords[i, :])
# Create VTK line and assign points to line.
line = vtk.vtkPolyLine()
line.GetPointIds().SetNumberOfIds(n_points)
for i in range(n_points):
line.GetPointIds().SetId(i, point_offset+i)
cells.InsertNextCell(line)
point_offset += n_points
data = vtk.vtkPolyData()
data.SetPoints(points)
data.SetLines(cells)
writer = vtk.vtkXMLPPolyDataWriter()
writer.SetInput(data)
if vtk.vtkVersion.GetVTKMajorVersion() > 5:
writer.SetInputData(data)
else:
writer.SetInput(data)
writer.SetFileName(args.out)
writer.Write()
if __name__ == '__main__':
main()

View file

@ -1,120 +1,125 @@
#!/usr/bin/env python2
from __future__ import division, print_function
import struct
import sys
################################################################################
def parse_options():
"""Process command line arguments"""
"""Process command line arguments"""
from optparse import OptionParser
usage = r"""%prog [options] <voxel_file>"""
p = OptionParser(usage=usage)
p.add_option('-o', '--output', action='store', dest='output',
default='plot', help='Path to output SILO or VTK file.')
p.add_option('-v', '--vtk', action='store_true', dest='vtk',
default=False, help='Flag to convert to VTK instead of SILO.')
parsed = p.parse_args()
if not parsed[1]:
p.print_help()
from optparse import OptionParser
usage = r"""%prog [options] <voxel_file>"""
p = OptionParser(usage=usage)
p.add_option('-o', '--output', action='store', dest='output',
default='plot', help='Path to output SILO or VTK file.')
p.add_option('-v', '--vtk', action='store_true', dest='vtk',
default=False, help='Flag to convert to VTK instead of SILO.')
parsed = p.parse_args()
if not parsed[1]:
p.print_help()
return parsed
return parsed
return parsed
################################################################################
def main(file_, o):
print(file_)
fh = open(file_, 'rb')
header = get_header(fh)
meshparms = (header['dimension'] + header['lower_left'] +
header['upper_right'])
nx, ny, nz = meshparms[:3]
ll = header['lower_left']
print(file_)
fh = open(file_,'rb')
header = get_header(fh)
meshparms = header['dimension'] + header['lower_left'] + header['upper_right']
nx,ny,nz = meshparms[0], meshparms[1], meshparms[2]
ll = header['lower_left']
if o.vtk:
try:
import vtk
except:
print('The vtk python bindings do not appear to be installed '
'properly.\nOn Ubuntu: sudo apt-get install python-vtk\n'
'See: http://www.vtk.org/')
return
if o.vtk:
try:
import vtk
except:
print('The vtk python bindings do not appear to be installed properly.\n'
'On Ubuntu: sudo apt-get install python-vtk\n'
'See: http://www.vtk.org/')
return
origin = [(l + w*n/2.) for n, l, w in
zip((nx, ny, nz), ll, header['width'])]
origin = [(l+w*n/2.) for n,l,w in zip((nx,ny,nz),ll,header['width'])]
grid = vtk.vtkImageData()
grid.SetDimensions(nx+1, ny+1, nz+1)
grid.SetOrigin(*ll)
grid.SetSpacing(*header['width'])
grid = vtk.vtkImageData()
grid.SetDimensions(nx+1,ny+1,nz+1)
grid.SetOrigin(*ll)
grid.SetSpacing(*header['width'])
data = vtk.vtkDoubleArray()
data.SetName("id")
data.SetNumberOfTuples(nx*ny*nz)
for x in range(nx):
sys.stdout.write(" {0}%\r".format(int(x/nx*100)))
sys.stdout.flush()
for y in range(ny):
for z in range(nz):
i = z*nx*ny + y*nx + x
id_ = get_int(fh)[0]
data.SetValue(i, id_)
grid.GetCellData().AddArray(data)
data = vtk.vtkDoubleArray()
data.SetName("id")
data.SetNumberOfTuples(nx*ny*nz)
for x in range(nx):
sys.stdout.write(" {0}%\r".format(int(x/nx*100)))
sys.stdout.flush()
for y in range(ny):
for z in range(nz):
i = z*nx*ny + y*nx + x
id_ = get_int(fh)[0]
data.SetValue(i, id_)
grid.GetCellData().AddArray(data)
writer = vtk.vtkXMLImageDataWriter()
if vtk.vtkVersion.GetVTKMajorVersion() > 5:
writer.SetInputData(grid)
else:
writer.SetInput(grid)
if not o.output.endswith(".vti"):
o.output += ".vti"
writer.SetFileName(o.output)
writer.Write()
writer = vtk.vtkXMLImageDataWriter()
writer.SetInput(grid)
if not o.output[-4:] == ".vti": o.output += ".vti"
writer.SetFileName(o.output)
writer.Write()
else:
try:
import silomesh
except:
print('The silomesh package does not appear to be installed '
'properly.\nSee: https://github.com/nhorelik/silomesh/')
return
if not o.output.endswith(".silo"):
o.output += ".silo"
silomesh.init_silo(o.output)
silomesh.init_mesh('plot', *meshparms)
silomesh.init_var("id")
for x in range(1, nx+1):
sys.stdout.write(" {0}%\r".format(int(x/nx*100)))
sys.stdout.flush()
for y in range(1, ny+1):
for z in range(1, nz+1):
id_ = get_int(fh)[0]
silomesh.set_value(float(id_), x, y, z)
print()
silomesh.finalize_var()
silomesh.finalize_mesh()
silomesh.finalize_silo()
else:
try:
import silomesh
except:
print('The silomesh package does not appear to be installed properly.\n'
'See: https://github.com/nhorelik/silomesh/')
return
if not o.output[-5:] == ".silo": o.output += ".silo"
silomesh.init_silo(o.output)
silomesh.init_mesh('plot', *meshparms)
silomesh.init_var("id")
for x in range(1,nx+1):
sys.stdout.write(" {0}%\r".format(int(x/nx*100)))
sys.stdout.flush()
for y in range(1,ny+1):
for z in range(1,nz+1):
id_ = get_int(fh)[0]
silomesh.set_value(float(id_), x, y, z)
print()
silomesh.finalize_var()
silomesh.finalize_mesh()
silomesh.finalize_silo()
################################################################################
def get_header(file_):
nx,ny,nz = get_int(file_, 3)
wx,wy,wz = get_double(file_, 3)
lx,ly,lz = get_double(file_, 3)
header = {'dimension':[nx,ny,nz], 'width':[wx,wy,wz], 'lower_left':[lx,ly,lz],
'upper_right': [lx+wx*nx,ly+wy*ny,lz+wz*nz]}
return header
nx, ny, nz = get_int(file_, 3)
wx, wy, wz = get_double(file_, 3)
lx, ly, lz = get_double(file_, 3)
header = {'dimension': [nx, ny, nz], 'width': [wx, wy, wz],
'lower_left': [lx, ly, lz],
'upper_right': [lx+wx*nx, ly+wy*ny, lz+wz*nz]}
return header
################################################################################
def get_data(file_, n, typeCode, size):
return list(struct.unpack('={0}{1}'.format(n,typeCode),
file_.read(n*size)))
return list(struct.unpack('={0}{1}'.format(n, typeCode),
file_.read(n*size)))
################################################################################
def get_int(file_, n=1, path=None):
return get_data(file_, n, 'i', 4)
return get_data(file_, n, 'i', 4)
################################################################################
def get_double(file_, n=1, path=None):
return get_data(file_, n, 'd', 8)
return get_data(file_, n, 'd', 8)
################################################################################
if __name__ == '__main__':
(options, args) = parse_options()
if args:
main(args[0],options)
(options, args) = parse_options()
if args:
main(args[0], options)

View file

@ -126,7 +126,7 @@ contains
if (master) call check_triggers()
#ifdef MPI
call MPI_BCAST(satisfy_triggers, 1, MPI_LOGICAL, 0, &
MPI_COMM_WORLD, mpi_err)
MPI_COMM_WORLD, mpi_err)
#endif
if (satisfy_triggers .or. &
(trigger_on .and. current_batch == n_max_batches)) then
@ -157,6 +157,9 @@ contains
! Copy source attributes to the particle
call copy_source_attributes(p, source_site)
! Determine whether to create track file
if (write_all_tracks) p % write_track = .true.
end subroutine sample_source_particle
end module fixed_source

View file

@ -197,12 +197,6 @@ contains
p % coord => p % coord % next
p % coord % universe = c % fill
! Determine all distribcell offsets for this cell level
if (.not. associated(p % coord % mapping)) then
allocate(p % coord % mapping(n_maps))
end if
p % coord % mapping(:) = c % offset(:)
! Apply translation
if (allocated(c % translation)) then
p % coord % xyz = p % coord % xyz - c % translation
@ -259,14 +253,6 @@ contains
! Move particle to next level and search for the lower cells.
p % coord => p % coord % next
! Determine all distribcell offsets for this cell level
if (lat % are_valid_indices(i_xyz)) then
if (.not. associated(p % coord % mapping)) then
allocate(p % coord % mapping(n_maps))
end if
p % coord % mapping(:) = lat % offset(:, i_xyz(1), i_xyz(2), i_xyz(3))
end if
call find_cell(p, found)
if (.not. found) exit
@ -629,12 +615,6 @@ contains
! Find cell in next lattice element
p % coord % universe = lat % universes(i_xyz(1), i_xyz(2), i_xyz(3))
! Determine all distribcell offsets for this lattice cell
if (.not. associated(p % coord % mapping)) then
allocate(p % coord % mapping(n_maps))
end if
p % coord % mapping(:) = lat % offset(:, i_xyz(1), i_xyz(2), i_xyz(3))
call find_cell(p, found)
if (.not. found) then
! In some circumstances, a particle crossing the corner of a cell may
@ -1603,7 +1583,7 @@ contains
end if
end subroutine handle_lost_particle
!===============================================================================
! CALC_OFFSETS calculates and stores the offsets in all fill cells. This
! routine is called once upon initialization.
@ -1630,12 +1610,12 @@ contains
offset = 0
do i = 1, n
cell_index = univ % cells(i)
! get pointer to cell
c => cells(cell_index)
! ====================================================================
! AT LOWEST UNIVERSE, TERMINATE SEARCH
if (c % type == CELL_NORMAL) then
@ -1664,7 +1644,7 @@ contains
select type (lat)
type is (RectLattice)
! Loop over lattice coordinates
do j = 1, lat % n_cells(1)
do k = 1, lat % n_cells(2)
@ -1702,9 +1682,9 @@ contains
end if
end do
end subroutine calc_offsets
!===============================================================================
! COUNT_TARGET recursively totals the numbers of occurances of a given
! universe ID beginning with the universe given.
@ -1744,18 +1724,18 @@ contains
count = 0
n = univ % n_cells
do i = 1, n
cell_index = univ % cells(i)
! get pointer to cell
c => cells(cell_index)
! ====================================================================
! AT LOWEST UNIVERSE, TERMINATE SEARCH
if (c % type == CELL_NORMAL) then
! ====================================================================
! CELL CONTAINS LOWER UNIVERSE, RECURSIVELY FIND CELL
elseif (c % type == CELL_FILL) then
@ -1767,7 +1747,7 @@ contains
count = count + 1
return
end if
count = count + count_target(next_univ, counts, found, goal, map)
c => cells(cell_index)
@ -1781,11 +1761,11 @@ contains
select type (lat)
type is (RectLattice)
! Loop over lattice coordinates
do j = 1, lat % n_cells(1)
do k = 1, lat % n_cells(2)
do m = 1, lat % n_cells(3)
do m = 1, lat % n_cells(3)
next_univ => universes(lat % universes(j, k, m))
! Found target - stop since target cannot contain itself
@ -1793,7 +1773,7 @@ contains
count = count + 1
cycle
end if
count = count + &
count_target(next_univ, counts, found, goal, map)
@ -1836,7 +1816,7 @@ contains
counts(universe_dict % get_key(univ % id), map) = count
found(universe_dict % get_key(univ % id), map) = .true.
end function count_target
!===============================================================================
@ -1859,7 +1839,7 @@ contains
n = univ % n_cells
do i = 1, n
cell_index = univ % cells(i)
! get pointer to cell
@ -1869,13 +1849,13 @@ contains
! ====================================================================
! AT LOWEST UNIVERSE, TERMINATE SEARCH
if (c % type == CELL_NORMAL) then
! ====================================================================
! CELL CONTAINS LOWER UNIVERSE, RECURSIVELY FIND CELL
elseif (c % type == CELL_FILL) then
next_univ => universes(c % fill)
call count_instance(next_univ)
c => cells(cell_index)
@ -1924,7 +1904,7 @@ contains
end if
end do
end subroutine count_instance

View file

@ -74,8 +74,8 @@ contains
type(Node), pointer :: node_verb => null()
type(Node), pointer :: node_res_scat => null()
type(Node), pointer :: node_scatterer => null()
type(Node), pointer :: node_trigger => null()
type(Node), pointer :: node_keff_trigger => null()
type(Node), pointer :: node_trigger => null()
type(Node), pointer :: node_keff_trigger => null()
type(NodeList), pointer :: node_scat_list => null()
! Display output message
@ -2394,9 +2394,9 @@ contains
! Set type of filter
t % filters(j) % type = FILTER_DISTRIBCELL
! Going to add new filters to this tally if n_words > 1
! Allocate and store bins
allocate(t % filters(j) % int_bins(n_words))
call get_node_array(node_filt, "bins", t % filters(j) % int_bins)
@ -2580,7 +2580,7 @@ contains
! Append default_xs specifier to nuclide if needed
if ((default_xs /= '') .and. (.not. ends_with(sarray(j), 'c'))) then
word = word // "." // default_xs
word = trim(word) // "." // default_xs
end if
! Search through nuclides
@ -2963,7 +2963,7 @@ contains
call fatal_error("No <scores> specified on tally " &
&// trim(to_str(t % id)) // ".")
end if
! If settings.xml trigger is turned on, create tally triggers
if (trigger_on) then

View file

@ -27,9 +27,6 @@ module particle_header
! Is this level rotated?
logical :: rotated = .false.
! Distributed Mapping Info
integer, pointer :: mapping(:) => null()
! Pointer to next (more local) set of coordinates
type(LocalCoord), pointer :: next => null()
end type LocalCoord
@ -104,9 +101,6 @@ contains
! recursively deallocate lower coordinates
if (associated(coord % next)) call deallocate_coord(coord%next)
! deallocate original coordinate
if (associated(coord % mapping)) deallocate(coord % mapping)
! deallocate this coord
deallocate(coord)
end if

View file

@ -1160,8 +1160,13 @@ contains
coord => p % coord0
offset = 0
do while(associated(coord))
if (associated(coord % mapping)) then
offset = offset + coord % mapping(t % filters(i) % offset)
if (cells(coord % cell) % type == CELL_FILL) then
offset = offset + cells(coord % cell) % &
offset(t % filters(i) % offset)
elseif(cells(coord % cell) % type == CELL_LATTICE) then
offset = offset + lattices(coord % next % lattice) % obj % &
offset(t % filters(i) % offset, coord % next % lattice_x, &
coord % next % lattice_y, coord % next % lattice_z)
end if
if (t % filters(i) % int_bins(1) == coord % cell) then
matching_bins(i) = offset + 1
@ -1170,7 +1175,7 @@ contains
coord => coord % next
end do
nullify(coord)
case (FILTER_CELLBORN)
! determine next cellborn bin
matching_bins(i) = get_next_bin(FILTER_CELLBORN, &

View file

@ -69,10 +69,12 @@ contains
// '_' // trim(to_str(current_gen)) // '_' // trim(to_str(p % id)) &
// '.binary'
#endif
!$omp critical
call binout % file_create(fname)
length = [3, n_tracks]
call binout % write_data(coords, 'coordinates', length=length)
call binout % file_close()
!$omp end critical
deallocate(coords)
end subroutine finalize_particle_track

View file

@ -121,7 +121,8 @@ class Test(object):
self.skipped = False
self.valgrind_cmd = ""
self.gcov_cmd = ""
self.cmake = ['cmake', '-H..', '-Bbuild']
self.cmake = ['cmake', '-H..', '-Bbuild',
'-DPYTHON_EXECUTABLE=' + sys.executable]
# Check for MPI/HDF5
if self.mpi and not self.hdf5:

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -36,7 +37,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.20.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -37,7 +38,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.20.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_created_output():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob('statepoint.10.*')
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.7.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -32,7 +33,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -79,7 +80,7 @@ def test_results():
statepoint.append(glob.glob(cwd + '/case-1/statepoint.1.*'))
statepoint.append(glob.glob(cwd + '/case-2/statepoint.1.*'))
statepoint.append(glob.glob(cwd + '/case-3/statepoint.3.*'))
call(['python', 'results.py', statepoint.pop()[0], statepoint.pop()[0], statepoint.pop()[0]])
call([sys.executable, 'results.py', statepoint.pop()[0], statepoint.pop()[0], statepoint.pop()[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -41,7 +42,7 @@ def test_statepoint_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_restart():
def test_results():
particle = glob.glob(os.path.join(cwd, 'particle_12_616.*'))
call(['python', 'results.py', particle[0]])
call([sys.executable, 'results.py', particle[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_restart():
def test_results():
particle = glob.glob(os.path.join(cwd, 'particle_7_6144.*'))
call(['python', 'results.py', particle[0]])
call([sys.executable, 'results.py', particle[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE
from optparse import OptionParser

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE
from optparse import OptionParser

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE
from optparse import OptionParser

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE
from optparse import OptionParser

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -86,7 +87,7 @@ def test_run2():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_statepoint_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.08.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_statepoint_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.08.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -35,7 +36,7 @@ def test_statepoint_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -35,7 +36,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')
@ -62,7 +63,7 @@ def test_created_statepoint_form1():
def test_results_form1():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')
@ -89,7 +90,7 @@ def test_created_statepoint_form2():
def test_results_form2():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')
@ -112,7 +113,7 @@ def test_created_statepoint_serial():
def test_results_serial():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -39,7 +40,7 @@ def test_statepoints_exist():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.09.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
import glob
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
@ -48,7 +49,7 @@ def test_statepoints_exist():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.07.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')
@ -56,7 +57,7 @@ def test_created_statepoint_form1():
def test_results_form1():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.07.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')
@ -81,7 +82,7 @@ def test_created_statepoint_form2():
def test_results_form2():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.07.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')
@ -102,7 +103,7 @@ def test_created_statepoint_serial():
def test_results_serial():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.07.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -35,7 +36,7 @@ def test_statepoint_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -34,7 +35,7 @@ def test_output_exists():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -33,7 +34,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -17,7 +17,7 @@ except ImportError:
exit()
# Run track processing script
call(['../../track.py', '-o', 'poly'] +
call(['../../scripts/openmc-track-to-vtk', '-o', 'poly'] +
glob.glob(''.join((cwd, '/track*'))))
poly = ''.join((cwd, '/poly.pvtp'))
assert os.path.isfile(poly), 'poly.pvtp file not found.'

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -32,7 +33,7 @@ def test_created_outputs():
'Track files not a binary or hdf5 file'
def test_outputs():
call(['python', 'results.py'])
call([sys.executable, 'results.py'])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.19.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.19.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.15.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

View file

@ -1,6 +1,7 @@
#!/usr/bin/env python
import os
import sys
from subprocess import Popen, STDOUT, PIPE, call
import filecmp
import glob
@ -31,7 +32,7 @@ def test_created_statepoint():
def test_results():
statepoint = glob.glob(os.path.join(cwd, 'statepoint.10.*'))
call(['python', 'results.py', statepoint[0]])
call([sys.executable, 'results.py', statepoint[0]])
compare = filecmp.cmp('results_test.dat', 'results_true.dat')
if not compare:
os.rename('results_test.dat', 'results_error.dat')

Some files were not shown because too many files have changed in this diff Show more