geo_extractor
Library to extract geo-related information from databases such as Bellingcat, Cen4InfoRes, DefMon3, GeoConfirmed and Texty.org.ua.
Installation
Install from PyPI:
pip install osint-geo-extractor
Usage
from geo_extractor import get_bellingcat_data
events = get_bellingcat_data()
for e in events[:10]:
print(f"{e.id}: [{e.latitude}, {e.longitude}]")
See also the examples/ folder.
Docs
Convenience functions:
get_bellingcat_dataget_ceninfores_dataget_defmon_dataget_defmon_spreadsheet_dataget_geoconfirmed_dataget_texty_data
Data is returned as a list of Event objects:
| Field | Type |
|---|---|
| id | str |
| date | datetime |
| latitude | float |
| longitude | float |
| place_desc | str |
| title | str |
| description | str |
| source | str |
| links | List[str] |
Data formats: See dataformats/
Exporting to GeoJSON: Use extractors.format_as_geojson(data)
{
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"id": "CIV0001",
"geometry": {
"type": "Point",
"coordinates": [
36.659031,
49.85005
]
},
"properties": {
"title": "<title>",
"date": "2022-02-24",
"description": "<desc>",
"links": [
"https://twitter.com/Michael1Sheldon/status/1496717647089651716",
"https://twitter.com/AFP/status/1496768532448788482"
],
"source": "BELLINGCAT"
}
}
]
}
Tests
To obtain necessary testing data not shipped with the repository, install the
package into your virtualenv via pip install -e ., navigate to
tests and run python generate_fixtures.py.
The tests can be run via pytest:
$ pip install pytest
$ PYTHONPATH=. pytest
To run a single test, use pytest -k <test name>.
To run the download tests that require an internet connection,
use pytest --online -k download.
License
MIT
Metadata
Release files for osint-geo-extractor 0.0.12
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| osint-geo-extractor-0.0.12.tar.gz | 20.0 kB | Without provenance | Details for osint-geo-extractor-0.0.12.tar.gz |
Release files / osint-geo-extractor-0.0.12.tar.gz
| Download URL | osint-geo-extractor-0.0.12.tar.gz |
|---|---|
| Size | 20.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7975a598cf702fb6c7089434633059b89c03f34995dc704ec5f29d4cc4f764f1
|
|
BLAKE2b-256 checksum How to use checksums |
a045460d5f1f09ccdfc0a33ac693f7f0ced05429bcc013fe3df261da29c0ef72
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.6
|
Security for osint-geo-extractor 0.0.12
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.