<div dir="ltr">[please keep it in the list]<br><br>On Thu, Jun 21, 2018 at 9:12 AM, Paul Shapley <<a href="mailto:p.shapley@gmail.com">p.shapley@gmail.com</a>> wrote:<br>><br>> Thank you Markus...here are the results of g.region -p and <a href="http://r.info">r.info</a><br>><br>> g.region -p                                                                     <br>> projection: 99 (OSGB 1936 / British National Grid)<br>> zone:       0<br>> datum:      osgb36<br>> ellipsoid:  airy<br>> north:      242815<br>> south:      200862.25<br>> west:       263134.25<br>> east:       298833.75<br>> nsres:      0.25<br>> ewres:      0.25<br>> rows:       167811<br>> cols:       142798<br>> cells:      23963075178<br>> (Thu Jun 21 08:03:51 2018) Command finished (0 sec)<br>><br>> (Thu Jun 21 08:08:02 2018)                                                      <br>> <a href="http://r.info">r.info</a> map=APGB_aerial_1.1@PERMANENT                                            <br>>  +----------------------------------------------------------------------------+<br>>  | Map:      APGB_aerial_1.1@PERMANENT      Date: Tue May 29 09:11:31 2018    |<br>>  | Mapset:   PERMANENT                      Login of Creator: administrator   |<br>>  | Location: TempLocation                                                     |<br>>  | DataBase: C:\                                                              |<br>>  | Title:    APGB_aerial_1.1                                                  |<br>>  | Timestamp: none                                                            |<br>>  |----------------------------------------------------------------------------|<br>>  |                                                                            |<br>>  |   Type of Map:  raster               Number of Categories: 0               |<br>>  |   Data Type:    CELL                                                       |<br>>  |   Rows:         167811                                                     |<br>>  |   Columns:      142798                                                     |<br>>  |   Total Cells:  23963075178                                                |<br>>  |        Projection: OSGB 1936 / British National Grid                       |<br>>  |            N:     242815    S:  200862.25   Res:  0.25                     |<br>>  |            E:  298833.75    W:  263134.25   Res:  0.25                     |<br>>  |   Range of data:    min = 0  max = 255                                     |<br>>  |                                                                            |<br>>  |   Data Description:                                                        |<br>>  |    generated by r.in.gdal                                                  |<br>>  |                                                                            |<br>>  |   Comments:                                                                |<br>>  |    r.in.gdal -o -k input="J:\Spatial Data\Aerial\APGB_received_20180416\   |<br>>  |    \source\RGB_25cm\output\test\JPEG.png" output="APGB_aerial_1" memory\   |<br>>  |    =300 offset=0 num_digits=0                                              |<br>>  |                                                                            |<br>>  +----------------------------------------------------------------------------+<br>> (Thu Jun 21 08:08:02 2018) Command finished (0 sec) <br><div><br></div><div>OK, so you really have a group of rasters with 24 billion cells. Still, do you really need to run i.segment on the full extents with such a high resolution? If yes, try i.segment with memory=25000. Even if the system has more RAM, the operating system and any other programs also need some RAM, therefore it is safer to not use all free memory. Be aware that i.segment will take a long time (several days) to process such a large region.</div><div><br></div><div>></div>> Should the output image from 'r.in.gdal' have had more memory allocated than the 300mb?<br><div><br></div><div>The memory option of r.in.gdal applies to the input image, not the output image. Sometimes more memory can help, sometimes it does not have any effect. However, it does not affect subsequent processing steps.</div><div><br></div><div>Markus M<br></div><div><br></div><div>></div>> Thanks again Markus...I appreciate your help.<br>><br>> Paul Shapley                          <br>><br>><br>>                            <br>><br>> On 20 June 2018 at 16:15, Markus Metz <<a href="mailto:markus.metz.giswork@gmail.com">markus.metz.giswork@gmail.com</a>> wrote:<br>>><br>>><br>>><br>>> On Wed, Jun 20, 2018 at 1:30 PM, Paul Shapley <<a href="mailto:p.shapley@gmail.com">p.shapley@gmail.com</a>> wrote:<br>>> ><br>>> > Hi Users,<br>>> ><br>>> > Apologies if i'm posting this error again but i need to get pass the memory allocation issue of trying to allocate 3gb memory. The Grass version is (using file r.contour). Processor has 32 gb ram and i've allocated 30000 mb under memory option of 'i.segment'.<br>>> ><br>>> > System Info                                                                    <br>>> > GRASS version: 7.4.1                                                            <br>>> > GRASS SVN revision: r72807                                                      <br>>> > Build date: 2018-06-13                                                          <br>>> > Build platform: i386-w64-mingw32                                                <br>>> > GDAL: 2.2.4                                                                    <br>>> > PROJ.4: 4.9.3                                                                  <br>>> > GEOS: 3.5.0                                                                    <br>>> > SQLite: 3.17.0                                                                  <br>>> > Python: 2.7.4                                                                  <br>>> > wxPython: 2.8.12.1                                                              <br>>> > Platform: Windows-2008ServerR2-6.1.7601-SP1 (OSGeo4W)                          <br>>> >                                                                                <br>>> ><br>>> > ERROR: G_malloc: unable to allocate 2995426350 bytes of memory at imagery/i.segment/flag.c:25<br>>><br>>> this error appears because all other memory has already been allocated, there is less than 3 GB free RAM left.<br>>><br>>> It seems that the current region has more than 20 billion grid cells. Does this match the input to i.segment? You might want to check the current region settings and compare them with extents and resolution as reported by <a href="http://r.info">r.info</a> on the input to i.segment.<br>>><br>>> Please provide the output of g.region -p and <a href="http://r.info">r.info</a> if you want more detailed help.<br>>><br>>> Markus M<br>>><br>>> ><br>>> > --<br>>> > Paul J. Shapley MSc CGeog (GIS) FRGS<br>>> ><br>>> ><br>>> > _______________________________________________<br>>> > grass-user mailing list<br>>> > <a href="mailto:grass-user@lists.osgeo.org">grass-user@lists.osgeo.org</a><br>>> > <a href="https://lists.osgeo.org/mailman/listinfo/grass-user">https://lists.osgeo.org/mailman/listinfo/grass-user</a><br>>><br>><br>><br>><br>> --<br>> Paul J. Shapley MSc CGeog (GIS) FRGS<br>><br></div>