[GRASS-user] v.out.ogr not working

Group,
I have been spending a lot of time on this and I need help. I am using grass72/ gdal2.2 and both my python script and grass72 are not producing the expected output when i run v.out.ogr! v.in.ogr does work though!

v.out.ogr input=parcel type=area output=/home/atourej/Data/prcl.shp

parcel has 1107 areas and program run in 0 second with no output!!

Your insight is appreciated

alassane

Hi Alassane,

maybe the problem can be the name size of columns in the attribute table.

Try with short name.

Best.

···

2018-01-09 22:56 GMT-02:00 alassane toure <atourej@gmail.com>:

Group,
I have been spending a lot of time on this and I need help. I am using grass72/ gdal2.2 and both my python script and grass72 are not producing the expected output when i run v.out.ogr! v.in.ogr does work though!

v.out.ogr input=parcel type=area output=/home/atourej/Data/prcl.shp

parcel has 1107 areas and program run in 0 second with no output!!

Your insight is appreciated

alassane


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

Maurício Humberto Vancine

Ecologist - Master Candidate in Zoology

São Paulo State University (UNESP), Rio Claro, SP, Brazil

Site | Lattes | ResearchGate | GitHub | ORCID | Google citations | Impactstory

GRASS GIS uses its internal vector format, so v.out.ogr just expects a map name.

If you want to write out SHP or other formats directly, check

https://grass.osgeo.org/grass72/manuals/v.external.out.html

HTH,
Markus

···

Am 10.01.2018 1:56 vorm. schrieb “alassane toure” <atourej@gmail.com>:

Group,
I have been spending a lot of time on this and I need help. I am using grass72/ gdal2.2 and both my python script and grass72 are not producing the expected output when i run v.out.ogr! v.in.ogr does work though!

v.out.ogr input=parcel type=area output=/home/atourej/Data/prcl.shp

On Wed, Jan 10, 2018 at 7:24 AM, Markus Neteler <neteler@osgeo.org> wrote:

Am 10.01.2018 1:56 vorm. schrieb “alassane toure” <atourej@gmail.com>:

Group,
I have been spending a lot of time on this and I need help. I am using grass72/ gdal2.2 and both my python script and grass72 are not producing the expected output when i run v.out.ogr! v.in.ogr does work though!

v.out.ogr input=parcel type=area output=/home/atourej/Data/prcl.shp

GRASS GIS uses its internal vector format, so v.out.ogr just expects a map name.

No, v.out.ogr expects an OGR datasource and optionally an OGR layer.

Try
v.out.ogr input=parcel type=area output=/home/atourej/Data output_layer=prcl

If this is also not working, please post the messages/warnings/errors of v.out.ogr.

Markus M

If you want to write out SHP or other formats directly, check

https://grass.osgeo.org/grass72/manuals/v.external.out.html

HTH,
Markus


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

Thanks for your response Mauricio.

Ok I will try it but v.out.ogr in GUI and in python script works using GRASS70 though!

alassane

···

On Tue, Jan 9, 2018 at 10:13 PM, Maurício Vancine <mauricio.vancine@gmail.com> wrote:

Hi Alassane,

maybe the problem can be the name size of columns in the attribute table.

Try with short name.

Best.

2018-01-09 22:56 GMT-02:00 alassane toure <atourej@gmail.com>:

Group,
I have been spending a lot of time on this and I need help. I am using grass72/ gdal2.2 and both my python script and grass72 are not producing the expected output when i run v.out.ogr! v.in.ogr does work though!

v.out.ogr input=parcel type=area output=/home/atourej/Data/prcl.shp

parcel has 1107 areas and program run in 0 second with no output!!

Your insight is appreciated

alassane


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

Maurício Humberto Vancine

Ecologist - Master Candidate in Zoology

São Paulo State University (UNESP), Rio Claro, SP, Brazil

Site | Lattes | ResearchGate | GitHub | ORCID | Google citations | Impactstory

Thanks Markus,
I will try your suggestion too!

alassane

···

On Wed, Jan 10, 2018 at 9:25 AM, alassane toure <atourej@gmail.com> wrote:

Thanks for your response Mauricio.

Ok I will try it but v.out.ogr in GUI and in python script works using GRASS70 though!

alassane

On Tue, Jan 9, 2018 at 10:13 PM, Maurício Vancine <mauricio.vancine@gmail.com> wrote:

Hi Alassane,

maybe the problem can be the name size of columns in the attribute table.

Try with short name.

Best.

2018-01-09 22:56 GMT-02:00 alassane toure <atourej@gmail.com>:

Group,
I have been spending a lot of time on this and I need help. I am using grass72/ gdal2.2 and both my python script and grass72 are not producing the expected output when i run v.out.ogr! v.in.ogr does work though!

v.out.ogr input=parcel type=area output=/home/atourej/Data/prcl.shp

parcel has 1107 areas and program run in 0 second with no output!!

Your insight is appreciated

alassane


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

Maurício Humberto Vancine

Ecologist - Master Candidate in Zoology

São Paulo State University (UNESP), Rio Claro, SP, Brazil

Site | Lattes | ResearchGate | GitHub | ORCID | Google citations | Impactstory

Markus,
Here is the system response. The code goes through the process but does not create the output file!

Inline image 1

···

On Wed, Jan 10, 2018 at 9:28 AM, alassane toure <atourej@gmail.com> wrote:

Thanks Markus,
I will try your suggestion too!

alassane

On Wed, Jan 10, 2018 at 9:25 AM, alassane toure <atourej@gmail.com> wrote:

Thanks for your response Mauricio.

Ok I will try it but v.out.ogr in GUI and in python script works using GRASS70 though!

alassane

On Tue, Jan 9, 2018 at 10:13 PM, Maurício Vancine <mauricio.vancine@gmail.com> wrote:

Hi Alassane,

maybe the problem can be the name size of columns in the attribute table.

Try with short name.

Best.

2018-01-09 22:56 GMT-02:00 alassane toure <atourej@gmail.com>:

Group,
I have been spending a lot of time on this and I need help. I am using grass72/ gdal2.2 and both my python script and grass72 are not producing the expected output when i run v.out.ogr! v.in.ogr does work though!

v.out.ogr input=parcel type=area output=/home/atourej/Data/prcl.shp

parcel has 1107 areas and program run in 0 second with no output!!

Your insight is appreciated

alassane


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

Maurício Humberto Vancine

Ecologist - Master Candidate in Zoology

São Paulo State University (UNESP), Rio Claro, SP, Brazil

Site | Lattes | ResearchGate | GitHub | ORCID | Google citations | Impactstory

On Wed, Jan 10, 2018 at 5:38 PM, alassane toure <atourej@gmail.com> wrote:

Markus,
Here is the system response. The code goes through the process but does not create the output file!

The first two errors make sense, you would need to use the --overwrite flag. The last call of v.out.ogr is strange because there are no output messages at all, even though there should be some. Can you try with GRASS 7.5?

Markus M

On Wed, Jan 10, 2018 at 9:28 AM, alassane toure <atourej@gmail.com> wrote:

Thanks Markus,
I will try your suggestion too!

alassane

On Wed, Jan 10, 2018 at 9:25 AM, alassane toure <atourej@gmail.com> wrote:

Thanks for your response Mauricio.

Ok I will try it but v.out.ogr in GUI and in python script works using GRASS70 though!

alassane

On Tue, Jan 9, 2018 at 10:13 PM, Maurício Vancine <mauricio.vancine@gmail.com> wrote:

Hi Alassane,

maybe the problem can be the name size of columns in the attribute table.

Try with short name.

Best.

2018-01-09 22:56 GMT-02:00 alassane toure <atourej@gmail.com>:

Group,
I have been spending a lot of time on this and I need help. I am using grass72/ gdal2.2 and both my python script and grass72 are not producing the expected output when i run v.out.ogr! v.in.ogr does work though!

v.out.ogr input=parcel type=area output=/home/atourej/Data/prcl.shp

parcel has 1107 areas and program run in 0 second with no output!!

Your insight is appreciated

alassane


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user


Maurício Humberto Vancine
Ecologist - Master Candidate in Zoology
São Paulo State University (UNESP), Rio Claro, SP, Brazil

Site | Lattes | ResearchGate | GitHub | ORCID | Google citations | Impactstory


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

Ok GRASS75 it will be. Will keep you posted!

Again thanks guys for making time for this

···

On Wed, Jan 10, 2018 at 5:14 PM, Markus Metz <markus.metz.giswork@gmail.com> wrote:

On Wed, Jan 10, 2018 at 5:38 PM, alassane toure <atourej@gmail.com> wrote:

Markus,
Here is the system response. The code goes through the process but does not create the output file!

The first two errors make sense, you would need to use the --overwrite flag. The last call of v.out.ogr is strange because there are no output messages at all, even though there should be some. Can you try with GRASS 7.5?

Markus M

On Wed, Jan 10, 2018 at 9:28 AM, alassane toure <atourej@gmail.com> wrote:

Thanks Markus,
I will try your suggestion too!

alassane

On Wed, Jan 10, 2018 at 9:25 AM, alassane toure <atourej@gmail.com> wrote:

Thanks for your response Mauricio.

Ok I will try it but v.out.ogr in GUI and in python script works using GRASS70 though!

alassane

On Tue, Jan 9, 2018 at 10:13 PM, Maurício Vancine <mauricio.vancine@gmail.com> wrote:

Hi Alassane,

maybe the problem can be the name size of columns in the attribute table.

Try with short name.

Best.

2018-01-09 22:56 GMT-02:00 alassane toure <atourej@gmail.com>:

Group,
I have been spending a lot of time on this and I need help. I am using grass72/ gdal2.2 and both my python script and grass72 are not producing the expected output when i run v.out.ogr! v.in.ogr does work though!

v.out.ogr input=parcel type=area output=/home/atourej/Data/prcl.shp

parcel has 1107 areas and program run in 0 second with no output!!

Your insight is appreciated

alassane


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user


Maurício Humberto Vancine

Ecologist - Master Candidate in Zoology
São Paulo State University (UNESP), Rio Claro, SP, Brazil

Site | Lattes | ResearchGate | GitHub | ORCID | Google citations | Impactstory


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

here is the error message from running the script (Grass72). I will install Grass75 today as i have no clue where to locate the error file and troubleshoot.

Inline image 1

···

On Wed, Jan 10, 2018 at 5:41 PM, alassane toure <atourej@gmail.com> wrote:

Ok GRASS75 it will be. Will keep you posted!

Again thanks guys for making time for this

On Wed, Jan 10, 2018 at 5:14 PM, Markus Metz <markus.metz.giswork@gmail.com> wrote:

On Wed, Jan 10, 2018 at 5:38 PM, alassane toure <atourej@gmail.com> wrote:

Markus,
Here is the system response. The code goes through the process but does not create the output file!

The first two errors make sense, you would need to use the --overwrite flag. The last call of v.out.ogr is strange because there are no output messages at all, even though there should be some. Can you try with GRASS 7.5?

Markus M

On Wed, Jan 10, 2018 at 9:28 AM, alassane toure <atourej@gmail.com> wrote:

Thanks Markus,
I will try your suggestion too!

alassane

On Wed, Jan 10, 2018 at 9:25 AM, alassane toure <atourej@gmail.com> wrote:

Thanks for your response Mauricio.

Ok I will try it but v.out.ogr in GUI and in python script works using GRASS70 though!

alassane

On Tue, Jan 9, 2018 at 10:13 PM, Maurício Vancine <mauricio.vancine@gmail.com> wrote:

Hi Alassane,

maybe the problem can be the name size of columns in the attribute table.

Try with short name.

Best.

2018-01-09 22:56 GMT-02:00 alassane toure <atourej@gmail.com>:

Group,
I have been spending a lot of time on this and I need help. I am using grass72/ gdal2.2 and both my python script and grass72 are not producing the expected output when i run v.out.ogr! v.in.ogr does work though!

v.out.ogr input=parcel type=area output=/home/atourej/Data/prcl.shp

parcel has 1107 areas and program run in 0 second with no output!!

Your insight is appreciated

alassane


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user


Maurício Humberto Vancine

Ecologist - Master Candidate in Zoology
São Paulo State University (UNESP), Rio Claro, SP, Brazil

Site | Lattes | ResearchGate | GitHub | ORCID | Google citations | Impactstory


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

Markus & Mauricio,
v.out.ogr now works under grass74. ESRI Shapefile is not a default and its specification is required.

v.out.ogr input=grassvector type=area format=ESRI_Shapefile output=dir/output.shp

Thanks for your help!!!

alassane

(attachments)

image.png

···

On Thu, Jan 11, 2018 at 9:15 AM, alassane toure <atourej@gmail.com> wrote:

here is the error message from running the script (Grass72). I will install Grass75 today as i have no clue where to locate the error file and troubleshoot.

Inline image 1

On Wed, Jan 10, 2018 at 5:41 PM, alassane toure <atourej@gmail.com> wrote:

Ok GRASS75 it will be. Will keep you posted!

Again thanks guys for making time for this

On Wed, Jan 10, 2018 at 5:14 PM, Markus Metz <markus.metz.giswork@gmail.com> wrote:

On Wed, Jan 10, 2018 at 5:38 PM, alassane toure <atourej@gmail.com> wrote:

Markus,
Here is the system response. The code goes through the process but does not create the output file!

The first two errors make sense, you would need to use the --overwrite flag. The last call of v.out.ogr is strange because there are no output messages at all, even though there should be some. Can you try with GRASS 7.5?

Markus M

On Wed, Jan 10, 2018 at 9:28 AM, alassane toure <atourej@gmail.com> wrote:

Thanks Markus,
I will try your suggestion too!

alassane

On Wed, Jan 10, 2018 at 9:25 AM, alassane toure <atourej@gmail.com> wrote:

Thanks for your response Mauricio.

Ok I will try it but v.out.ogr in GUI and in python script works using GRASS70 though!

alassane

On Tue, Jan 9, 2018 at 10:13 PM, Maurício Vancine <mauricio.vancine@gmail.com> wrote:

Hi Alassane,

maybe the problem can be the name size of columns in the attribute table.

Try with short name.

Best.

2018-01-09 22:56 GMT-02:00 alassane toure <atourej@gmail.com>:

Group,
I have been spending a lot of time on this and I need help. I am using grass72/ gdal2.2 and both my python script and grass72 are not producing the expected output when i run v.out.ogr! v.in.ogr does work though!

v.out.ogr input=parcel type=area output=/home/atourej/Data/prcl.shp

parcel has 1107 areas and program run in 0 second with no output!!

Your insight is appreciated

alassane


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user


Maurício Humberto Vancine

Ecologist - Master Candidate in Zoology
São Paulo State University (UNESP), Rio Claro, SP, Brazil

Site | Lattes | ResearchGate | GitHub | ORCID | Google citations | Impactstory


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

On Thu, Jan 11, 2018 at 6:08 PM, alassane toure <atourej@gmail.com> wrote:

Markus & Mauricio,
v.out.ogr now works under grass74.

Excellent!

ESRI Shapefile is not a default and its specification is required.

Yes, because we switched to GeoPackage vector as the default export
vector format in GRASS GIS 7.4:

https://trac.osgeo.org/grass/wiki/Release/7.4.0-News#Majormodulechanges
--> v.out.ogr: ...

v.out.ogr input=grassvector type=area format=ESRI_Shapefile output=dir/output.shp

Thanks for your help!!!

Glad that it now works,

markusN

On Thu, Jan 11, 2018 at 9:02 PM, Markus Neteler <neteler@osgeo.org> wrote:

On Thu, Jan 11, 2018 at 6:08 PM, alassane toure <atourej@gmail.com> wrote:

Markus & Mauricio,
v.out.ogr now works under grass74.

Excellent!

It is a pity that the GUI does not report the actual error.

ESRI Shapefile is not a default and its specification is required.

Yes, because we switched to GeoPackage vector as the default export
vector format in GRASS GIS 7.4:

GeoPackage is the recommended vector output format, please use it!

Markus M

https://trac.osgeo.org/grass/wiki/Release/7.4.0-News#Majormodulechanges
→ v.out.ogr: …

v.out.ogr input=grassvector type=area format=ESRI_Shapefile output=dir/output.shp

Thanks for your help!!!

Glad that it now works,

markusN