Skip to content
Snippets Groups Projects
Commit a7b67af9 authored by David Verelst's avatar David Verelst
Browse files

more debugging on why 2 tests on runner are not passing

parent 7e542b22
No related branches found
No related tags found
No related merge requests found
Pipeline #
......@@ -396,7 +396,11 @@ def create_chunks_htc_pbs(cases, sort_by_values=['[Windspeed]'], ppn=20, i0=0,
cc = Cases(cases)
df = cc.cases2df()
# sort on the specified values in the given columns
df.sort_values(by=sort_by_values, inplace=True)
# sort_valures was only added in Pandas 0.17
try:
df.sort_values(by=sort_by_values, inplace=True)
except AttributeError:
df.sort(columns=sort_by_values, inplace=True)
# create the directory to store all zipped chunks
try:
......
......@@ -122,9 +122,13 @@ class Tests(unittest.TestCase):
data = np.loadtxt(fname)
self.assertEqual(data.shape, df_data.shape)
print(data.dtype)
print(data.values.dtype)
print(data)
print(data.values)
print(df_data.values.dtype)
for i in range(data.shape[0]):
a = data[i,:]
b = df_data.values[i,:]
if not np.allclose(a,b):
print(a-b)
np.testing.assert_almost_equal(a, b)
np.testing.assert_almost_equal(data, df_data.values, decimal=6)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment