Это один из подходов.
Пример:
result = []
base_val = ''
with open(filename) as infile:
for line in infile:
line = line.strip()
if line: #Check if line is empty
if line.startswith("*"):
base_val = line.lstrip("*").strip().split() #Get Date line
else:
result.append(base_val + line.split()) #Form required list
print(result)
Выход:
[
['2019', '7', '8', '0', '0', '0.00000000', 'PE01', '-29225.002062', '-4252.742792', '-1915.262327', '-642.336192'],
['2019', '7', '8', '0', '0', '0.00000000', 'PE02', '29239.941616', '4214.548704', '1856.791406', '68.271625'],
['2019', '7', '8', '0', '0', '0.00000000', 'PE03', '19764.216366', '9479.291699', '19908.151379', '-185.782224'],
['2019', '7', '8', '0', '0', '0.00000000', 'PE04', '-13231.353497', '11725.555035', '-23729.152873', '-318.666487'],
['2019', '7', '8', '0', '0', '0.00000000', 'PE05', '14751.386626', '25291.823093', '4375.095547', '-468.399018'],
['2019', '7', '8', '0', '0', '0.00000000', 'PE07', '-1119.264400', '-26235.644241', '13662.554654', '-222.074278'],
['2019', '7', '8', '0', '0', '0.00000000', 'PE08', '12962.777246', '-11868.521398', '23825.978428', '6327.578380'],
['2019', '7', '8', '0', '0', '0.00000000', 'PE09', '1464.297128', '26224.237620', '-13655.240745', '6385.654050'],
['2019', '7', '8', '0', '0', '0.00000000', 'PE11', '-9700.857653', '25890.523336', '-10555.310714', '5659.403360'],
['2019', '7', '8', '0', '5', '0.00000000', 'PE01', '-29157.478195', '-4205.546295', '-2830.114774', '-642.338623'],
['2019', '7', '8', '0', '5', '0.00000000', 'PE02', '29174.220890', '4167.267005', '2771.685480', '68.272131'],
['2019', '7', '8', '0', '5', '0.00000000', 'PE03', '20017.069289', '10012.927817', '19387.676411', '-185.783486'],
['2019', '7', '8', '0', '5', '0.00000000', 'PE04', '-13530.293652', '11074.197778', '-23872.919410', '-318.668867'],
['2019', '7', '8', '0', '5', '0.00000000', 'PE05', '14809.564246', '25394.936573', '3489.967606', '-468.398037']
]