You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fitparse uses many many objects and many of them are of RecordBase, The RecordBase.__init__ is a bit slow. E.g. I've tried to optimize FieldData.__init__:
And parsing of event_timestamp.fit has sped up by 0.8 sec. Generally, the getattr, hasattr and setattr slows down the process when used so extensively.
I may create PR to change all RecordBase and descendants init. But there's a remark in the records.py:
# TODO: switch back to namedtuple, and don't use default arguments as None# and see if that gives us any performance improvements
Note: Also, the processor.py uses getattr, extensivelly.
The text was updated successfully, but these errors were encountered:
fitparse uses many many objects and many of them are of
RecordBase
, TheRecordBase.__init__
is a bit slow. E.g. I've tried to optimizeFieldData.__init__
:And parsing of
event_timestamp.fit
has sped up by 0.8 sec. Generally, thegetattr
,hasattr
andsetattr
slows down the process when used so extensively.I may create PR to change all
RecordBase
and descendants init. But there's a remark in therecords.py
:Note: Also, the
processor.py
usesgetattr
, extensivelly.The text was updated successfully, but these errors were encountered: