Closed georgeslabreche closed 3 years ago
Used:
f_q = open('quaternion.txt', 'r')
f_q_line = f_q.read()
f_q_line = f_q_line.split()
date_time_str = f_q_line[0] + ' ' + f_q_line[1]
date_time_obj = datetime.strptime(date_time_str, '%Y-%m-%d %H:%M:%S.%f')
Instead of this: https://github.com/BenDB3199/Attitude_from_quaterions/blob/2652221e4459defa3480e511e178650a9bcacc3f/interpret_TM_short.py#L24-L29
You'll want to use
datetime.datetime.strptime
. Here's a tutorial: https://stackabuse.com/converting-strings-to-datetime-in-python/