IOMRC / gentleR-n-Pyceful

Repository for weekly meeting of IOMRC people learning Python and R
GNU General Public License v3.0
3 stars 1 forks source link

Tuesday 8th October #6

Open ghost opened 4 years ago

ghost commented 4 years ago

Hi all, Tomorrow Nick is going to step me (and hopefully you too!) through reading corrupt binary files from a Nortek Vector and saving the output. It should be an interesting session on a real case spanning a few packages and computer wizardry.

Oceanworks at 12pm. I will bring Tim Tams.

Chris

mrayson commented 4 years ago

As a followup to today's chat re: reading binary files in python.

In the past I have used numpy.fromfile function that seems to do the trick. Some sample code is here where I used it to read the OSU tide model files: https://github.com/mrayson/soda/blob/python3pip/soda/dataio/conversion/readotps.py#L395

I found it more intuitive than the struct package. You can jump around in the file using the seek function (like C/matlab).

Matt

On Mon, Oct 7, 2019 at 12:02 PM chriswhitwell notifications@github.com wrote:

Hi all, Tomorrow Nick is going to step me (and hopefully you too!) through reading corrupt binary files from a Nortek Vector and saving the output. It should be an interesting session on a real case spanning a few packages and computer wizardry.

Oceanworks at 12pm. I will bring Tim Tams.

Chris

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/IOMRC/gentleR-n-Pyceful/issues/6?email_source=notifications&email_token=AC73RFACMXM5USDEQNR2XEDQNKYFBA5CNFSM4I57MUSKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HP6RNVQ, or mute the thread https://github.com/notifications/unsubscribe-auth/AC73RFBHBYI7ULJP2KBIJTTQNKYFBANCNFSM4I57MUSA .

-- Matt Rayson

Research Fellow Australian Research Council Industrial Transformation Research Hub for Offshore Floating Facilities Oceans Graduate School and the UWA Oceans Institute University of Western Australia

Ph: +61 8 6488 3083