Re: Reduce numbers to one number




Socrates wrote:
Hello Robert - Each text file will represent one image. The pixel
values line by line can also be outputted to a graph, which is a
different way of storing and displaying the pixel values compared to
storing the values as a sequence of numbers or characters.

A graph of pixel values is an alternative way of storing and looking at
an image, but at the moment I am more interested in storing an image as
a text file.

Obviously there is nothing new in the idea of storing an image as a
text file - one could reconstruct an image manually by knowing the
values of each pixel. The only advantage is in automating this process,
with the added benefit if desired of encrypting the contents.

There is actually no difference between images and text files, except
what
programs you use to work with them. Compression programs such as
zip will run on any file, and often achieve good results. I don't know
why you think this is new.

And of course text files can be compressed much more than any jpg with
the added value that the compression is lossless - the same pixel
values are available whenever the file is opened.

Any compression method works because most of the files it deals with
are
highly predictable. In English text, "e" occurs often and "¿" hardly
ever.
Moreover, some sequences of characters are common and others are not.
If you read a text up to a certain point, you can probably make a good
guess
at what the next character is going to be. Bit-map image files (such
as .bmp)
are also quite predictable, but often in different ways: e.g. you may
have large
areas of the image with the same pixel values. Methods of compression
that
work well with text may not work well with images, and vice versa.

However, .jpg files are already compressed, so they have very little
predictability,
and compression methods are unlikely to be able to compress them much
more.

Robert Israel israel@xxxxxxxxxxx
Department of Mathematics http://www.math.ubc.ca/~israel
University of British Columbia Vancouver, BC, Canada

.



Relevant Pages

  • Re: Reduce numbers to one number
    ... different way of storing and displaying the pixel values compared to ... storing the values as a sequence of numbers or characters. ... A graph of pixel values is an alternative way of storing and looking at ... the calculation would need to be ...
    (sci.math)
  • Re: Differential intra-interchannel filters for RGB images lossless compression
    ... >>> However IMHO many photographic images are even slightly more difficult ... don't look right, lighting doesn't look right, surfaces are almost always ... compression, it seems concievable to me that they could. ... would likely be able to fairly accurately predict the pixel. ...
    (comp.compression)
  • Re: recommendation for digital camera -=> Shameless Nikon plug
    ... > because each pixel is only R, G, or B straight from the CCD.) ... In the tiff file you have three colors per pixel and 8 bits per ... lossless compression and not uncompressed versus compressed, ... That should rival the Nikon capture software. ...
    (Debian-User)
  • Re: File Size Question
    ... In 8 bit JPEG format, it takes 3 bytes to represent one pixel. ... your 10 Megapixel camera makes IMAGES that are around 30 Megabytes. ... JPEG uses highly efficient lossey compression. ...
    (rec.photo.digital)
  • Re: Raw File Formats
    ... camera) for each pixel which accounts for the bulk of the information, ... color channel but, for an 8 MP camera, this would result in a 36MB (1.5 ... Using compression this can be reduced to less than 8 Mb. ... Offcours changes occuring a lot should get short codes, changes occuring less should get long codes. ...
    (rec.photo.digital.slr-systems)