Skip to content

Instantly share code, notes, and snippets.

@JesperDramsch
Created September 10, 2013 21:49
Show Gist options
  • Save JesperDramsch/6516233 to your computer and use it in GitHub Desktop.
Save JesperDramsch/6516233 to your computer and use it in GitHub Desktop.
This line of code extracts the EBCDIC header of SEG-Y data and makes it human readable in ASCII encoding.
dd bs=3200 count=1 conv=ascii if=data.segy | sed 's/.\{80\}/&\n/g' | sed 's/^.\{3\}/& /g' > header.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment