mobilitydb_datagen
mobilitydb_datagen
mobilitydb : MobilityDB random data generator functions
Overview
| ID | Extension | Package | Version | Category | License | Language |
|---|---|---|---|---|---|---|
| 1651 | mobilitydb_datagen
|
mobilitydb
|
1.3.0 |
GIS
|
GPL-3.0
|
SQL
|
| Attribute | Has Binary | Has Library | Need Load | Has DDL | Relocatable | Trusted |
|---|---|---|---|---|---|---|
----d-r
|
No
|
No
|
No
|
Yes
|
yes
|
no
|
| Relationships | |
|---|---|
| Requires | mobilitydb
|
| See Also | mobilitydb
postgis
timescaledb
pgrouting
|
| Siblings | mobilitydb
|
Packages
| Type | Repo | Version | PG Major Compatibility | Package Pattern | Dependencies |
|---|---|---|---|---|---|
| EXT | PGDG
|
1.3.0 |
18
17
16
15
14
|
mobilitydb |
mobilitydb |
| DEB | PGDG
|
1.3.0 |
18
17
16
15
14
|
postgresql-$v-mobilitydb |
- |
| Linux / PG | PG18 | PG17 | PG16 | PG15 | PG14 |
|---|---|---|---|---|---|
el8.x86_64
|
MISS
|
MISS
|
MISS
|
MISS
|
MISS
|
el8.aarch64
|
MISS
|
MISS
|
MISS
|
MISS
|
MISS
|
el9.x86_64
|
MISS
|
MISS
|
MISS
|
MISS
|
MISS
|
el9.aarch64
|
MISS
|
MISS
|
MISS
|
MISS
|
MISS
|
el10.x86_64
|
MISS
|
MISS
|
MISS
|
MISS
|
MISS
|
el10.aarch64
|
MISS
|
MISS
|
MISS
|
MISS
|
MISS
|
d12.x86_64
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
d12.aarch64
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
d13.x86_64
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
d13.aarch64
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
u22.x86_64
|
MISS
|
PGDG 1.2.0
|
PGDG 1.2.0
|
PGDG 1.2.0
|
PGDG 1.2.0
|
u22.aarch64
|
MISS
|
PGDG 1.2.0
|
PGDG 1.2.0
|
PGDG 1.2.0
|
PGDG 1.2.0
|
u24.x86_64
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
u24.aarch64
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
PGDG 1.3.0
|
Source
Install
Make sure PGDG repo available:
pig repo add pgdg -u # add pgdg repo and update cacheInstall this extension with pig:
pig install mobilitydb; # install via package name, for the active PG version
pig install mobilitydb_datagen; # install by extension name, for the current active PG version
pig install mobilitydb_datagen -v 18; # install for PG 18
pig install mobilitydb_datagen -v 17; # install for PG 17
pig install mobilitydb_datagen -v 16; # install for PG 16
pig install mobilitydb_datagen -v 15; # install for PG 15
pig install mobilitydb_datagen -v 14; # install for PG 14Create this extension with:
CREATE EXTENSION mobilitydb_datagen CASCADE; -- requires mobilitydbUsage
mobilitydb_datagen: Synthetic mobility data generator for MobilityDB
MobilityDB DataGen provides functions for generating synthetic mobility data for testing and benchmarking MobilityDB workloads. It creates random temporal values including trips, trajectories, and time-varying measurements.
Generating Random Temporal Values
-- Generate a random temporal float over a time span
SELECT random_tfloat(
'2025-06-01 00:00+00', '2025-06-02 00:00+00', -- time span
0.0, 100.0, -- value range
10 -- number of instants
);
-- Generate a random temporal geometric point (trajectory)
SELECT random_tgeompoint(
'2025-06-01 08:00+00', '2025-06-01 18:00+00', -- time span
ST_MakeEnvelope(2.2, 48.8, 2.4, 48.9, 4326), -- spatial bounds
20 -- number of instants
);Generating Test Datasets
Create bulk test data for benchmarking trip queries:
INSERT INTO trips (vehicle_id, trip, trip_date)
SELECT
i,
random_tgeompoint(
'2025-06-01 08:00+00', '2025-06-01 18:00+00',
ST_MakeEnvelope(2.2, 48.8, 2.5, 48.9, 4326),
50
),
'2025-06-01'
FROM generate_series(1, 1000) AS i;Last updated on