-
-
Notifications
You must be signed in to change notification settings - Fork 62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add CLI and listeners to reverse geocode pictures' coordinates #1310
Conversation
/backport to stable25 |
40ba055
to
3d80638
Compare
9bc8195
to
03a153d
Compare
3d80638
to
af2731c
Compare
03a153d
to
bfaaab6
Compare
6bb4679
to
01ee346
Compare
2d310e1
to
0063898
Compare
0063898
to
b852838
Compare
|
||
use OC\Metadata\FileMetadata; | ||
|
||
class PhotosFile { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review hint: extracted from AlbumFile
so it can be shared with LocationFile
309b238
to
ece1721
Compare
private int $size; | ||
private int $mtime; | ||
private string $etag; | ||
class AlbumFile extends PhotosFile { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review hint: extracted to PhotosFile
so it can be shared with LocationFile
520924d
to
42dc0a5
Compare
3fecbd9
to
4d4f6fd
Compare
419dcc9
to
5f5fc2f
Compare
5db737a
to
24dda33
Compare
The location data is stored inside `oc_files_metadata`. - `occ photos:update-1000-cities` to update the cities1000 file. - `occ photos:map-media-to-location`to map picture coordinates to a location - `ReverseGeoCoderService` download the necessary files and build the `KDTree` - `UpdateReverseGeocodingFilesCommand` command to allow to manually create the needed reverse geocoding files - `MediaLocationManager` to manager the location mappings - `MapMediaToLocationCommand` command to manually trigger location data mapping. Useful for pre-existing pictures. - `LocationManagerNodeEventListener` to react to node, user and share events. - `MapMediaToLocationJob` to reduce the load in event listeners ```php ┌─────────────────────┐ ┌────────────►│MapMediaToLocationJob│ │ └─────────┬───────────┘ │ │ ┌────────────────────────┴───────┐ │ │LocationManagerNodeEventListener├──┐ ▼ └────────────────────────────────┘ │ ┌────────────────────┐ ┌──────────────┐ ├─►│MediaLocationManager├────►│LocationMapper│ ┌─────────────────────────┐ │ └─────────┬──────────┘ └──────────────┘ │MapMediaToLocationCommand├─────────┘ │ └─────────────────────────┘ │ ▼ ┌──────────────────────────────────┐ ┌──────────────────────┐ │UpdateReverseGeocodingFilesCommand├──►│ReverseGeoCoderService│ └──────────────────────────────────┘ └──────────────────────┘ ``` Signed-off-by: Louis Chemineau <louis@chmn.me>
24dda33
to
d94f30c
Compare
Add commands and listeners to generate location data of files:
The location data is stored inside
oc_files_metadata
.Added commands
occ photos:update-1000-cities
to update the cities1000 file.occ photos:map-media-to-location
to map picture coordinates to a locationArchitecture
ReverseGeoCoderService
download the necessary files and build theKDTree
UpdateReverseGeocodingFilesCommand
command to allow to manually create the needed reverse geocoding filesMediaLocationManager
to manager the location mappingsMapMediaToLocationCommand
command to manually trigger location data mapping. Useful for pre-existing pictures.LocationManagerNodeEventListener
to react to node, user and share events.MapMediaToLocationJob
to reduce the load in event listeners