File size: 425 Bytes
1342024 a3864e2 1342024 a3864e2 1342024 a3864e2 1342024 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
import traceback
try:
train_max=400
t = open("./2024-01/position_names_tags.txt",'r')
train = open("./2024-01/train.txt","w")
test = open("./2024-01/test.txt","w")
for i,l in enumerate(t):
if i <= train_max:
train.write(l)
else:
test.write(l)
t.close()
train.close()
test.close()
except Exception as e:
print(e)
print(traceback.format_exc())
|