<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Bathymetry .xyz data to raster in 3D Questions</title>
    <link>https://community.esri.com/t5/3d-questions/bathymetry-xyz-data-to-raster/m-p/401461#M2349</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;There is an old 9.1 script available here: &lt;/SPAN&gt;&lt;A href="http://arcscripts.esri.com/details.asp?dbid=12876"&gt;http://arcscripts.esri.com/details.asp?dbid=12876&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;There are also numerous discussions on this topic in the old forums. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I used to used the tool often a few years ago for all of my LiDAR and bathymetry XYZ to ASCII Grid conversions and it worked well.&amp;nbsp; I also used it only a few weeks ago &lt;/SPAN&gt;&lt;STRONG&gt;with version 10.0&lt;/STRONG&gt;&lt;SPAN&gt; to convert extremely large Lidar Full Feature XYZ files to ASCII grid raster files and it worked just fine.&amp;nbsp; It did through an error when attempting to convert ASCCI Grid files to ESRI Grid but that step is not needed since ArcGIS displays ASCII grid raster files natively. I have never tried running the slope and contours operations (the tool has options for those) because those steps can be easily done with the Spatial Analyst.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 05 Sep 2012 14:40:19 GMT</pubDate>
    <dc:creator>JakubSisak</dc:creator>
    <dc:date>2012-09-05T14:40:19Z</dc:date>
    <item>
      <title>Bathymetry .xyz data to raster</title>
      <link>https://community.esri.com/t5/3d-questions/bathymetry-xyz-data-to-raster/m-p/401459#M2347</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I received some bathymetry data in .xyz format and am trying to figure out how to convert it to a DEM or raster of some sort. I need to generate some bathymetry profile graphs for a client. When I opened the text file to view the data, it is just one field with x,y,z data all together. The x,y data is in State Plane and the Z data is in NAVD88. The file is rather large (13.2mb) and when I tried to copy and paste the data into Excel to try and separate the data into separate fields, I received an error that not all of the data was copied (which I assume is because the file is too large?) Can anyone let me know how to convert this file into a raster?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Aug 2012 10:54:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/3d-questions/bathymetry-xyz-data-to-raster/m-p/401459#M2347</guid>
      <dc:creator>JoshuaCoates</dc:creator>
      <dc:date>2012-08-14T10:54:27Z</dc:date>
    </item>
    <item>
      <title>Re: Bathymetry .xyz data to raster</title>
      <link>https://community.esri.com/t5/3d-questions/bathymetry-xyz-data-to-raster/m-p/401460#M2348</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Joshua,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Have you tried the &lt;/SPAN&gt;&lt;A href="http://resources.arcgis.com/en/help/main/10.1/index.html#/ASCII_3D_To_Feature_Class/00q900000041000000/"&gt;ASCII 3D to Feature Class &lt;/A&gt;&lt;SPAN&gt;tool?&amp;nbsp; This will get you points that you can convert to raster or use to interpolate a raster.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Best,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Eric&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Aug 2012 15:19:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/3d-questions/bathymetry-xyz-data-to-raster/m-p/401460#M2348</guid>
      <dc:creator>EricRice</dc:creator>
      <dc:date>2012-08-14T15:19:14Z</dc:date>
    </item>
    <item>
      <title>Re: Bathymetry .xyz data to raster</title>
      <link>https://community.esri.com/t5/3d-questions/bathymetry-xyz-data-to-raster/m-p/401461#M2349</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;There is an old 9.1 script available here: &lt;/SPAN&gt;&lt;A href="http://arcscripts.esri.com/details.asp?dbid=12876"&gt;http://arcscripts.esri.com/details.asp?dbid=12876&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;There are also numerous discussions on this topic in the old forums. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I used to used the tool often a few years ago for all of my LiDAR and bathymetry XYZ to ASCII Grid conversions and it worked well.&amp;nbsp; I also used it only a few weeks ago &lt;/SPAN&gt;&lt;STRONG&gt;with version 10.0&lt;/STRONG&gt;&lt;SPAN&gt; to convert extremely large Lidar Full Feature XYZ files to ASCII grid raster files and it worked just fine.&amp;nbsp; It did through an error when attempting to convert ASCCI Grid files to ESRI Grid but that step is not needed since ArcGIS displays ASCII grid raster files natively. I have never tried running the slope and contours operations (the tool has options for those) because those steps can be easily done with the Spatial Analyst.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Sep 2012 14:40:19 GMT</pubDate>
      <guid>https://community.esri.com/t5/3d-questions/bathymetry-xyz-data-to-raster/m-p/401461#M2349</guid>
      <dc:creator>JakubSisak</dc:creator>
      <dc:date>2012-09-05T14:40:19Z</dc:date>
    </item>
    <item>
      <title>Re: Bathymetry .xyz data to raster</title>
      <link>https://community.esri.com/t5/3d-questions/bathymetry-xyz-data-to-raster/m-p/401462#M2350</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I recently had do something similar, convert rather large xyz files (up to 1.2GB) to rasters. Since the old script never really worked for me, i tried something with python/numpy. Making things a bit more complicated was the fact that in the xyz file records with no-data were simply omitted.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
import numpy as np
import arcpy

# Inputs
xyzfile = "e:/file.xyz"
outname = "e:/raster.asc"
skiprows = 1
delimiter = ","

ncols = 5974
nrows = 5505
xllcorner = 682000
yllcorner = 205000
cellsize = 1.0
nodataval = -9999

zgrid = np.zeros((nrows,ncols), dtype=np.float32)
zgrid.fill(nodataval)

# process the xyz file
with open(xyzfile) as f:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; # if header found in xyz file, skip line 1
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if skiprows == 1: 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; next(f)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; # put all available xyz values into correct positions on the zeros grid, 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; # all other positions keep the nodatavalue&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for line in f:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; item = line.rstrip().split(delimiter)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #print item 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; idx = (float(item[0])-xllcorner) / cellsize
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; idy = (float(item[1])-yllcorner) / cellsize
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; zgrid[idy,idx] = item[2]

# write the header and grid to an ascii file
with open(outname, "w") as outfile:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; # write ascii raster header
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; outfile.write("ncols " + str(int(ncols))+ "\n")
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; outfile.write("nrows " + str(int(nrows))+ "\n")
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; outfile.write("xllcorner " + str(xllcorner) + "\n")
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; outfile.write("yllcorner " + str(yllcorner) + "\n")
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; outfile.write("cellsize " + str(cellsize) + "\n")
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; outfile.write("nodata " + str("%.2f" % float(nodataval)) + "\n" + "\n")
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; # write grid to outfile
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; np.savetxt(outfile,zgrid[::-1], fmt="%.2f", delimiter= " ")
&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 18:18:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/3d-questions/bathymetry-xyz-data-to-raster/m-p/401462#M2350</guid>
      <dc:creator>RaphaelR</dc:creator>
      <dc:date>2021-12-11T18:18:46Z</dc:date>
    </item>
  </channel>
</rss>

