I have my data something like this
SERIAL FIRSTOCCURRENCE
NETPROTOCOL
1947430693 07/01/2009 05:16:40
FR
SERIAL FIRSTOCCURRENCE
NETPROTOCOL
1947430746 07/01/2009 05:18:05
FR
I want the output as follows.... (1 Reply)
Hi
I m having ifconfig -a o/p like
sbanlab1:ksh# ifconfig -a | egrep "flags|inet" | awk -F' ' '{print $1,$2}'
lo0: flags=2001000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4,VIRTUAL>
inet 127.0.0.1
lo0:1: flags=2001000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4,VIRTUAL>
inet 127.0.0.1
bge0:... (1 Reply)
Hello,
Need help substituting a particular word in a file having a single line but no newline character at the end.
I was trying to use sed but it doesn't work probably because there is no newline char at the end of the line.
$ cat hlq_detail
/outputs/alvan23/PDFs/bills
$ cat... (5 Replies)
I have several hundreds of tiny files which need to be concatenated into one single line and all those in a single file. Some files have several blank lines. Tried to use this script but failed on it.
awk 'END { print r } r && !/^/ { print FILENAME, r; r = "" }{ r = r ? r $0 : $0 }' *.txt... (8 Replies)
I have a file, I need to remove the first character of each line, but only if it's a comma. I don't want to delete any other commas in each line.
Trying cat or sed but I really don't know them very well, would love some help.
This removes the first comma, but it removes the first comma no... (6 Replies)
here is what i want to achieve.. i have a file with below contents
cat fileName
blah blah blah
.
.DROP this
REJECT that
.
--sport 7800 -j REJECT --reject-with icmp-port-unreachable
--dport 7800 -j REJECT --reject-with icmp-port-unreachable
.
.
.
more blah blah blah
--dport 3306... (14 Replies)
Hi Gurus,
I need separate one file which is one huge line to mutiple line.
file like
abcd # bcd # def # fge # ged
I want to get
abcd
bcd
def
fge
ged
Thanks in advance (4 Replies)
example of problem:
when I echo "$e" >> /home/cogiz/file.txt
result prints to file as:AA
BB
CC
I need it to save to file as this:AA BB CC
I know it's probably something really simple but any help would be greatly appreciated.
Thank You.
Cogiz (7 Replies)
I wish to generate output of two commands in the same line separated by a single white-space.
Below is my command and output in the same line.
ls -ltr fname1.out | awk '{$2=$4=$5=x; print}' | tr '\n' '\t' | tr -s ' '; cksum<fname1.out | cut -d' ' -f1
Output:
-rw-r--r--. root Aug 26 16:57... (6 Replies)
Discussion started by: mohtashims
6 Replies
LEARN ABOUT SUSE
pfm
PFM Format Description(5) File Formats Manual PFM Format Description(5)NAME
PFM - PFM graphic image file format
DESCRIPTION
This document describes the PFM graphic image file format as understood by the Netpbm converters pamtopfm(1)
and pfmtopam(1)
There are multiple similar formats known as PFM in the world, none of them authoritatively documented. The format described here is one
that Bryan Henderson deduced from a program he found somewhere that dealt with a 'PFM' format.
The PFM format is inspired by the Netpbm formats, and you will see lots of similarity. It is not, however, an official Netpbm format. Its
goal is not consistent with those of Netpbm formats.
The format
A PFM image is a stream of bytes. The stream consists of a header followed immediately by a raster. These two components are described
below. There are no delimeters before or after the sections as described.
PFM header
The PFM header is 3 consecutive 'lines' of ASCII text. After each line is a white space character. That character is typically a newline
character, hence the term 'line,' but doesn't have to be.
pamtopfm uses a newline in the PFM it generates.
Identifier Line
The identifier line contains the characters 'PF' or 'Pf'. PF means it's a color PFM. Pf means it's a grayscale PFM.
Dimensions Line
The dimensions line contains two positive decimal integers, separated by a blank. The first is the width of the image; the second is the
height. Both are in pixels.
Scale Factor / Endianness
The Scale Factor / Endianness line is a queer line that jams endianness information into an otherwise sane description of a scale. The
line consists of a nonzero decimal number, not necessarily an integer. If the number is negative, that means the PFM raster is little
endian. Otherwise, it is big endian. The absolute value of the number is the scale factor for the image.
The scale factor tells the units of the samples in the raster. You use somehow it along with some separately understood unit information
to turn a sample value into something meaningful, such as watts per square meter.
PFM raster
The raster is a sequence of pixels, packed one after another, with no delimiters of any kind. They are in standard Western reading order:
left to right and top to bottom within the image.
Each pixel consists of 1 or 3 samples, packed one after another, with no delimiters of any kind. 1 sample for a grayscale PFM and 3 for a
color PFM (see the Identifier Line of the PFM header).
Each sample consists of 4 consecutive bytes. The bytes represent a 32 bit string, in either big endian or little endian format, as deter-
mined by the Scale Factor / Endianness line of the PFM header. That string is an IEEE 32 bit floating point number code. Since that's the
same format that most CPUs and compiler use, you can usually just make a program use the bytes directly as a floating point number, after
taking care of the endianness variation.
netpbm documentation PFM Format Description(5)