i.tape.other(1)        Grass User's Manual	  i.tape.other(1)



NNAAMMEE
       ii..ttaappee..ootthheerr   - An imagery function that extracts scanned
       aerial imagery (NHAP, etc.)  and  satellite  imagery  (TM,
       SPOT, etc) from half-inch or 8mm tape.
       _(_G_R_A_S_S _I_m_a_g_e _P_r_o_c_e_s_s_i_n_g _P_r_o_g_r_a_m_)

SSYYNNOOPPSSIISS
       ii..ttaappee..ootthheerr

DDEESSCCRRIIPPTTIIOONN
       _i_._t_a_p_e_._o_t_h_e_r  is  a  generic program that extracts imagery
       from tape using the tape description that is input by  the
       user.


       This  program  must  be	run in a LOCATION_NAME with a x,y
       coordinate system (i.e., a coordinate system with  projec-
       tion  0).   For	further  information regarding this LOCA-
       TION_NAME refer to the manual entry for _i_m_a_g_e_r_y.


       The first prompt in _i_._t_a_p_e_._o_t_h_e_r asks  the  user  for  the
       tape  device  name.   This  is sometimes  /dev/rmt0 (for a
       density of 1600), but this varies with each machine.


       The next prompt is:

       Please mount and load tape, then hit RETURN


IIMMAAGGEE IIDDEENNTTIIFFIICCAATTIIOONN MMEENNUU
       The first menu in the program asks the user  for  informa-
       tion about the data.

	     please enter the following information

       Tape Identification:				__

       Image Description:				__

       Title for the Extracted Raster (Cell) Files:	__

       AFTER COMPLETING ALL ANSWERS, HIT <ESC> TO CONTINUE
		     (OR <Ctrl-C> TO CANCEL)


TTAAPPEE LLAAYYOOUUTT MMEENNUU
       The next menu asks for the physical layout of the tape.

				  GENERIC TAPE EXTRACTION

       tape layout
	   0__	     number of tape files to be skipped
	   0__	     number of records in the remaining files to
		     be skipped
       band files
	   0__	     number of bands on the tape
       data format
	   ___	     band sequential (BSQ)  |  mark one with an x
	   ___	     band interleaved (BIL) |
	   0__	     if you select BSQ format and all  the  bands
       are
		     in  a single file, enter the total number of
       records
		     in the file. Otherwise enter 0
	   0__	     length (in bytes) of the longest  record  on
       the tape
	   1__	     blocking factor of data in the file

		    AFTER  COMPLETING  ALL  ANSWERS, HIT <ESC> TO
       CONTINUE
				  (OR <Ctrl-C> TO CANCEL)


       _n_u_m_b_e_r _o_f _t_a_p_e _f_i_l_e_s _t_o _b_e _s_k_i_p_p_e_d
	      If there are files at the  beginning  of	the  tape
	      which  are  not  image  data,  they can be skipped.
	      Sometimes information that comes with a  tape  will
	      indicate	the  number of header files or records on
	      the tape.  The GRASS  utility  _m_._e_x_a_m_i_n_e_._t_a_p_e  will
	      also  provide  this information.	The _r_e_c_o_r_d _l_e_n_g_t_h
	      is the number of columns in the  image,  while  the
	      _n_u_m_b_e_r  _o_f  _r_e_c_o_r_d_s  is  the  number of rows in the
	      image (not always correct, see _b_l_o_c_k_i_n_g  _f_a_c_t_o_r  _o_f
	      _d_a_t_a  _i_n	_t_h_e _f_i_l_e below). NHAP imagery and usually
	      most scanned aerial imagery do not have tape header
	      files,  but this should be checked.  TM imagery has
	      one header file that  contains  imagery  format  of
	      data files and parameters of data aquisition.  SPOT
	      imagery has two files that should be skipped on the
	      first  tape, and one file to be skipped on the sec-
	      ond tape (of a two-tape set).

       _n_u_m_b_e_r _o_f _r_e_c_o_r_d_s _i_n _t_h_e _r_e_m_a_i_n_i_n_g _f_i_l_e_s _t_o _b_e _s_k_i_p_p_e_d
	      If the files which contain  the  image  begin  with
	      non-image  data, these records can also be skipped.
	      This is usually 0 for most data types. SPOT imagery
	      stored  in  1600bpi  has	one  header record in the
	      image file on each tape that should be skipped.

       _n_u_m_b_e_r _o_f _b_a_n_d_s _o_n _t_h_e _t_a_p_e
	      Most aerial imagery have	3  bands,  but	satellite
	      simulator  data  may  have more.	TM data has seven
	      bands and SPOT  has  three  bands  as  a	standard,
	      respectively. The total number of bands on the tape
	      should be specified here, not just the number  that
	      will be extracted.

       _d_a_t_a _f_o_r_m_a_t
	      The two formats that imagery data are most commonly
	      stored in are called _b_a_n_d _i_n_t_e_r_l_e_a_v_e_d format  (BIL)
	      and  _b_a_n_d  _s_e_q_u_e_n_t_i_a_l format (BSQ).  In BIL format,
	      each record on the tape contains one line  for  one
	      band  of	data.	If the data contains three bands,
	      then the first five records will look like this:

	      band 1, line 1
	      band 2, line 1
	      band 3, line 1
	      band 1, line 2
	      band 2, line 2

	      In BSQ format, all lines of  one	band  are  stored
	      together	on  a  tape,  followed	by  all  lines of
	      another band, followed by all  lines  of	the  next
	      band,  etc.   These data are stored as if they were
	      in a one band BIL format:

	      band 1, line 1
	      band 1, line 2
	      band 1, line 3
		   .
		   .
		   .
	      band 2, line 1
	      band 2, line 2
		   .
		   .
	      band 2, line 156
	      band 2, line 157

	      Each pixel contains one byte and there is one  line
	      per  record.  BSQ format is the format that is usu-
	      ally created by optical scanning devices when  they
	      scan  photographs,  but  not  all  digitized aerial
	      imagery are stored in this format.  The  format  of
	      the  data is usually written on the exterior of the
	      tape;  this should be checked.

       _l_e_n_g_t_h _(_i_n _b_y_t_e_s_) _o_f _t_h_e _l_o_n_g_e_s_t _r_e_c_o_r_d _o_n _t_h_e _t_a_p_e
	      This must be set to the  number  of  bytes  in  the
	      longest  data  record.  It is used to determine how
	      large a buffer to use for reading  the  tape.  This
	      value can be obtained using _m_._e_x_a_m_i_n_e_._t_a_p_e_.

       _b_l_o_c_k_i_n_g _f_a_c_t_o_r _o_f _d_a_t_a _i_n _t_h_e _f_i_l_e
	      This  is	the  number  of  lines combining into one
	      physical record on tape.	It  is	usually  one  for
	      most  of	imageries,  i.e.,  one	line per physical
	      record.  However, considering on	data  compressing
	      and  tape  memory  saving,  sometimes more than one
	      lines are combined into one physical record on  the
	      tape.   This  number may be written on the exterior
	      of the tape, otherwise the user need to  experiment
	      on this number by running of _i_._t_a_p_e_._o_t_h_e_r.


BBAANNDD EEXXTTRRAACCTTIIOONN MMEENNUU
       The user is then asked to mark an _x beside the bands to be
       extracted.  See the subheading in this entry enTITLEd  ROW
       AND COLUMN EXTRACTION.

	please mark an x by the bands you want extracted

			      _____1
			      _____2
			      _____3
			      _____4


       AFTER COMPLETING ALL ANSWERS, HIT <ESC> TO CONTINUE
		     (OR <Ctrl-C> TO CANCEL)


PPRREEFFIIXX//GGRROOUUPP NNAAMMEE
       The  user  is  asked  to  enter	the  prefix/group for the
       (raster) band files to be created.  This name will precede
       each  band  file  extracted  into  GRASS.  For example, if
       three bands are extracted the following three  band  files
       will result:


       _p_r_e_f_i_x_n_a_m_e_._1
       _p_r_e_f_i_x_n_a_m_e_._2
       _p_r_e_f_i_x_n_a_m_e_._3


       The  specified  _p_r_e_f_i_x_n_a_m_e  will also automatically become
       the name for the imagery group file being  created.   Each
       image  (i.e.,  each run of _i_._t_a_p_e_._o_t_h_e_r) should be given a
       unique prefix/group name.

RROOWW AANNDD CCOOLLUUMMNN MMEENNUU
       Finally, the starting row, ending row, starting column and
       ending  column  are  required.  This  allows  the  user to
       extract any subset of the image from the tape.

			     EXTRACT
       please select desired tape window (geographic region
       definition) to extract
			  start row:_0_
			    end row:_0_

			  start col:_0_
			    end col:_0_

       AFTER COMPLETING ALL ANSWERS, HIT <ESC> TO CONTINUE
		     (OR <Ctrl-C> TO CANCEL)

       The extraction process will begin by  first  skipping  the
       number  of specified files, advancing to the starting row,
       and then reading the tape.  The percent completion of  the
       extraction is displayed on the screen.


       Following the extraction, the extracted band files will be
       listed as raster  map  layers  available  in  the  current
       MAPSET.	These raster map layers may be displayed individ-
       ually  using  the  GRASS  commands  _d_._d_i_s_p_l_a_y,  _d_._r_a_s_t  or
       _i_._p_o_i_n_t_s.

NNOOTTEESS
       This  program  can  be used for extraction of TM, SPOT and
       other types of data from tape;	however,  the  user  must
       supply information to the program on how the image data is
       laid out on the tape.  For example, the image data may  be
       padded  with  surrounding  extra  rows and/or columns; the
       user may wish to skip over  these  rows	and  columns  and
       extract	 only  the  actual  image  data  from  the  tape.
       _i_._t_a_p_e_._o_t_h_e_r does  not  know  where  image  data  actually
       begins  on  the tape;  the user must tell the program what
       portion of the tape data to extract.   Often,  information
       on  the	orientation  and layout of the image data on tape
       will be included on a printout accompanying any tape  data
       received by the user;  however, this may not always be the
       case.  The user may need to experiment with  various  runs
       of _i_._t_a_p_e_._o_t_h_e_r before extracting the portions of an image
       actually desired.


       After extracting an image from tape, the geographic region
       in  the	x,y  coordinate  LOCATION_NAME will be set, based
       upon the extracted rows and columns  from  the  tape.  The
       relationship  between  the  image rows and columns and the
       coordiates bounding the geographic region is discussed  in
       the _i_m_a_g_e_r_y manual entry.


       This  program  is interactive and requires no command line
       arguments.

RROOWW AANNDD CCOOLLUUMMNN EEXXTTRRAACCTTIIOONN
       The display options in GRASS allow the user to locate rows
       and columns on the digital image.  If enough disk space is
       available, one band of an entire image, or one band  of	a
       portion of an image known to contain the area of interest,
       can be extracted and displayed.	The  _m_e_a_s_u_r_e_m_e_n_t_s  option
       in  _d_._d_i_s_p_l_a_y, or _d_._w_h_e_r_e (following a run of _d_._r_a_s_t) will
       echo x and y coordinates to the	screen.   (These  coordi-
       nates  will  display  negative  numbers in the north-south
       direction but ignoring the negative sign  will  yield  the
       row  number.   See  the	_i_m_a_g_e_r_y  manual entry for further
       explanation.)


       If a photograph of the digital  image  is  available,  the
       rows and columns to be extracted can be determined from it
       by associating inches with the total number of known  rows
       and  columns  in  the  scene.   For  example, if the total
       length of the photograph is 12 inches, the total number of
       rows  on the tape is 2000, and the northwest corner of the
       area of interest begins 2  inches  from	the  top  of  the
       photo, then:

	       12" / 2000 rows = 2" / x rows
	       x = 333.333

       The northwest corner of the area of interest starts at row
       333.  The starting row, ending row, starting  column,  and
       ending column can be calculated in this manner.

SSEEEE AALLSSOO
       _G_R_A_S_S _T_u_t_o_r_i_a_l_: _I_m_a_g_e _P_r_o_c_e_s_s_i_n_g


       _d_._d_i_s_p_l_a_y

       _d_._r_a_s_t

       _d_._w_h_e_r_e

       _i_._g_r_o_u_p

       _i_._p_o_i_n_t_s

       _i_._t_a_p_e_._m_s_s

       _i_._t_a_p_e_._m_s_s_._h

       _i_._t_a_p_e_._t_m

       _i_._t_a_p_e_._t_m_._f_a_s_t

       _i_m_a_g_e_r_y

       _m_._e_x_a_m_i_n_e_._t_a_p_e

AAUUTTHHOORRSS
       Michael	 Shapiro,   U.S.Army   Construction   Engineering
       Research Laboratory
       Tao Wen, University of Illinois at Urbana-Champaign, Illi-
       nois

       _L_a_s_t _c_h_a_n_g_e_d_: _$_D_a_t_e_: _2_0_0_2_/_0_1_/_2_5 _0_5_:_4_5_:_3_3 _$



GRASS 5.0					  i.tape.other(1)
