Rakesh
Rakesh

Reputation: 31

Opening MDF4 (.mf4) file using python

I am trying to read .mf4 file using python 3.7 (Spyder IDE). The main idea of reading .mf4 file is to see if I can access each information separately. That means, for example, to check the Road Signs detection points only or Pedestrian identifications only or to extract video only.. and at the later stage to count the FP/FN/TP/TN and link it to the frame counter using GPS data.

I tried to use asammdf library.

Following is the function i used:

from asammdf import MDF, Signal
data = MDF('filename.mf4')

I get the error as follows :

bus_type = channel_group.acq_source.bus_type

AttributeError: 'NoneType' object has no attribute 'bus_type'

Upvotes: 3

Views: 21255

Answers (2)

Renija Roy
Renija Roy

Reputation: 1

You can use this:

from asammdf import MDF, Signal

mdf= MDF(version ="4.10")

path=mdf("file path")

Upvotes: 0

danielhrisca
danielhrisca

Reputation: 730

I've pushed a fix to the development branch.

You can install the code by running:

pip install -I --no-deps https://github.com/danielhrisca/asammdf/archive/development.zip

If you have other problems please open a new issue on github

Upvotes: 2

Related Questions