Geolife GPS trajectory dataset example

This demo imports into GemStone the Geolife GPS trajectory dataset .

This is a GPS trajectory dataset collected in (Microsoft Research Asia) GeoLife project by 182 users in a period of over three years (from April 2007 to August 2012).

The code of the demo is already in Glamorous Toolkit, however, for some views gtoolkit-mapper should be installed.

Metacello new
    baseline: 'GToolkitMapperWithoutGT';
    repository: 'github://feenkcom/gtoolkit-mapper:master/src';
    load
  

The snippet below configures the location to the folder containing the database.

datasetLocation := FileLocator home / 'Downloads'.
  

The snippet below imports the dataset in the current image. usersCount: configures the number of users to import.

directory :=  datasetLocation / 'Geolife Trajectories 1.3'.
localImporter := GtRmGeolifeLocalImporter new
	usersCount:  5.

geoLife := localImporter importFromDirectory: directory
  

The following snippet imports the user data within a GemStone extent. The default session is used for importing.

directory := FileLocator home / 'Downloads' / 'Geolife Trajectories 1.3'.
gemstoneImporter := GtRmGeolifeGemstoneImporter new
	usersCount:  25.

gemstoneImporter importFromDirectory: directory 
  

The imported data can be seen by inspecting the default instance of GtRmGeolife Object subclass: #GtRmGeolife instanceVariableNames: 'users' classVariableNames: 'DEFAULT' package: 'GToolkit-RemotePhlow-GeolifeDemo' .

GtRmGeolife defaultInstance