feat: split poli not nemeth

This commit is contained in:
Krzysztof Rudnicki 2024-11-28 18:10:18 +01:00
parent c847f006c2
commit 9d49ea894f
4 changed files with 6 additions and 12 deletions

4
.gitattributes vendored
View File

@ -2,5 +2,5 @@ code/poli3.npz filter=lfs diff=lfs merge=lfs -text
code/nemeth12.npz filter=lfs diff=lfs merge=lfs -text
code/spd_5000.npz filter=lfs diff=lfs merge=lfs -text
code/spd_10000.npz filter=lfs diff=lfs merge=lfs -text
code/nemeth12_1.npz filter=lfs diff=lfs merge=lfs -text
code/nemeth12_2.npz filter=lfs diff=lfs merge=lfs -text
code/poli3_1.npz filter=lfs diff=lfs merge=lfs -text
code/poli3_2.npz filter=lfs diff=lfs merge=lfs -text

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:80e15c0c8668a0edd86a7b76067885c2dd4872d436c47752d334522e468be526
size 722988846

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:07b828133018898a6bcc3d1983c142a9aaf5f9955d1ccf00dc9fb502d366ec96
size 542

View File

@ -1,7 +1,7 @@
import numpy as np
# Load the .npz file
input_file = 'code/nemeth12.npz'
input_file = 'code/poli3.npz'
data = np.load(input_file)
# Create dictionaries to hold the split data
@ -11,7 +11,7 @@ first_half = {key: data[key] for key in data_keys[:split_point]}
second_half = {key: data[key] for key in data_keys[split_point:]}
# Save the halves to separate .npz files
np.savez('nemeth12_1.npz', **first_half)
np.savez('nemeth12_2.npz', **second_half)
np.savez('poli3_1.npz', **first_half)
np.savez('poli3_2.npz', **second_half)
print(f"Data split into 'nemeth12_1.npz' and 'nemeth12_2.npz'")
print(f"Data split into 'poli3_1.npz' and 'poli3_2.npz'")