fixed size read bug and added tests

This commit is contained in:
Erik Frojdh
2023-06-04 18:57:49 +02:00
parent d9828dd9a3
commit b8a8891c8d
3 changed files with 61 additions and 13 deletions

View File

@ -40,4 +40,21 @@ with open(path/'37frames_with_5_clusters.clust', 'wb') as f:
data['data'] = np.arange(j,j+9)
print(data)
data.tofile(f)
#Writing out data to test noise cuts
header[1] = 7
with open(path/'noise_test.clust', 'wb') as f:
for i in range(10):
data['x'] = 50
data['y'] = 133
data['data'][:] = 50
header.tofile(f)
print(header)
header[0] += 1
for j in range(7):
print(data)
data.tofile(f)
data['x'] += 10