TripleGeo icon indicating copy to clipboard operation
TripleGeo copied to clipboard

Fail to convert my own shapefiles to RDF

Open Naurah opened this issue 9 years ago • 1 comments

Hi.. sorry for asking again.

I've tested this tool by using given 'points.shp' data and it was successfully converted to RDF. Then, I want to try converting my own point shapefiles. I have configure the shp_options.conf file by specified the path of input and output file. However, the conversion process is failed.

I got an error message that said:

Exception in thread "main" java.io.IOException: No such type : points at org.geotools.data.shapefile.ShapefileDataStore.typeCheckShapefileDataStore.java:577 at org.geotools.data.shapefile.ShapefileDataStore.getSchemaShapefileDataStore.java:631 at org.geotools.data.shapefile.ShapefileDataStore.getFeatureSource.ShapefileDataStore.java:964 at eu.geoknow.athenarc.triplegeo.shape.ShpConnector.getShapeFileFeatureCollectionSHpConnector.java:125 at eu.geoknow.athenarc.triplegeo.shape.ShpConnector.ShpConnector.java:99 at eu.geoknow.athenarc.triplegeo.ShpToRdf.mainShpToRdf.java:40

Hope you can help me.

Thousand thanks in advance.

Naurah avatar Nov 08 '15 04:11 Naurah

Hello and thanks for your feedback.

In the case of SHAPEFILES, configuration parameters have the following meaning:

  • featureString --> the name of the shapefile (without the extension .shp);
  • attribute --> the attribute in the shapefile that contains values to be used as (unique) identifiers in URIs and as string literals in "rdfs:label" triples;
  • ignore --> specifies values (e.g., UNK) in attributes that should not be exported as literals; NULL values are automatically suppressed;
  • type --> defines a user-defined name for the resources that will be created; you may specify any valid string (with no wild characters) you wish;
  • name --> attribute in the shapefile containing values that should be extracted as name literals; such values will become the objects of "georesource:name" triples;
  • class --> attribute in the shapefile containing values that should be extracted as type literals; such values will become objects of "rdf:type" triples.

Note that parameters are slightly different if data is to be exported from databases. Complete details can be found in the system manual (Section 3.3 of http://svn.aksw.org/projects/GeoKnow/Public/D2.2.1_Integration_of_Geospatial_Databases.pdf).

I hope that this clarifies the parametrization of TripleGeo for shapefiles.

KostasPatroumpas avatar Nov 08 '15 09:11 KostasPatroumpas