Skip to main content

A script to select photos from a set, based on geographical location.

Project description

# geoselect

A script to select photos from a set, based on geographical location. Either via a decimal latitude/longitude point.
Or a photo taken in the desired location, it will look for exif standerized gps lat- and longitude tags.

## Installing

### Pip
The easiest way is to use pip to download and install the script.

pip install geoselect


### Get (latest) source

# clone this repo
clone https://github.com/FreekKalter/geoselect.git
cd geoselect

# initialize virtual environment (optional, but recommended)
virtualenv venv
source venv/bin/activate

# install (--editable to hack on code whithout running pip install again)
pip install --editable .

## Using

There are 2 ways to specify the location to select on. LOCATION can be a "latitude,longitude" specified in decimal degrees like: "41.40338, 2.17403".
Or it can be a path to a photo with exif gps coordinates, it will then search for photos taken at the same location.
It will search within a specifie radius (default: 1 km).

If `--path` is set, geoselect will look for images with common file extensions (jpg, jpeg, gif, bmp, png). This can be set to something else with the `--extensions` parameter.
If `--path` is not set, paths to pictures are taken from stdinput. So now it can be used as a stream filter, like most unix/linux commandline utils.
For example the following pipeline:
`find /home/fkalter/photos -name '*holiday*' | geoselect --radius 10 "40.783068, -73.965350" | wc -l`
To count the number of pictures taken in/around central park wich have 'holiday' in the filename.



A (expiremental) feature uses the time a picture is taken to "gues" at wich location it is made. Sometimes the device used to make the picture takes a while to get a 'gps fix'.
So it might not register the gps coordinates for the first picture in a series. The `-- time-based` option looks for any pictures taken in a short time before or after a picture with the specified location is taken. Because it is very likely pictures taken very shortly after each ohter are taken at roughly the same location.

```

usage: geoselect.py [-h] [--path PATH] [--extentions EXTENTIONS] [--copy-to COPYTO] [--time-based] [--radius RADIUS]
[-V]
location

A script to select photos from a set, based on geographical location. Either via a decimal latitude/longitude point.
Or a photo taken in the desired location, it will look for exif standerized gps lat- and longitude tags.

positional arguments:
location location given in decimal degrees like: "40.783068, -73.965350", or a path to a photo with
exif gps info

optional arguments:
-h, --help show this help message and exit
--path PATH path to look for image files, if not set files will be taken from stdin
--extentions EXTENTIONS
comma separated list of extension to look for in PATH
--copy-to COPYTO path where found photos should be copied
--time-based also add photos wich themselfs dont have gps information, but are taken in a short time
before or after one that has (in the right location)
--radius RADIUS radius of area (in kilometers) to select photos from
-V, --version show program's version number and exit
```

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

geoselect-0.2.0.tar.gz (5.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

geoselect-0.2.0-py2.7.egg (9.7 kB view details)

Uploaded Egg

File details

Details for the file geoselect-0.2.0.tar.gz.

File metadata

  • Download URL: geoselect-0.2.0.tar.gz
  • Upload date:
  • Size: 5.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for geoselect-0.2.0.tar.gz
Algorithm Hash digest
SHA256 ef610ab86acd62c766cae88244f204df9e7f8ae8d470db443b5df2b3dba9af4b
MD5 2404189fa0b0a2de270d9449083e3888
BLAKE2b-256 c23db1bc8a7e081d759947e99006301265174293d235342b9fb8913b6eadfd10

See more details on using hashes here.

File details

Details for the file geoselect-0.2.0-py2.7.egg.

File metadata

  • Download URL: geoselect-0.2.0-py2.7.egg
  • Upload date:
  • Size: 9.7 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for geoselect-0.2.0-py2.7.egg
Algorithm Hash digest
SHA256 969fec06a1bcff579ca0bea064eddf8d07b137634b29bbd331ac896a06f0bddb
MD5 1ea7788479daa788d2640bd0cd2b0e4c
BLAKE2b-256 02d8c5aee1084703b525eacf4adb54a343fca5d471007b2cb3f9d121522ba647

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page