Code Monkey home page Code Monkey logo

xemle / home-gallery Goto Github PK

View Code? Open in Web Editor NEW
774.0 15.0 56.0 1.63 MB

Self-hosted open-source web gallery to view your photos and videos featuring mobile-friendly, tagging and AI powered image discovery

Home Page: https://home-gallery.org

License: MIT License

JavaScript 63.77% Dockerfile 0.17% TypeScript 33.22% Nearley 0.57% CSS 0.01% HTML 0.49% Shell 0.05% Mustache 1.71%
gallery videos open-source web-gallery mobile geo-reverse-lookups photo-gallery reverse-image-search tagging photos

home-gallery's People

Contributors

biolds avatar gitter-badger avatar jimenezrick avatar joe128 avatar martadinata666 avatar psdimon avatar vinzk avatar xemle avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

home-gallery's Issues

[improvement] Implement panning

When dealing with huge sized photos (e.g. Historic maps), it would be great to be able to pan and zoom the image without having to go back to its reduced display, and double click.
I would recommend OpenSeaDragon as the best open source library to achieve the result.

Datenschutz anpassen.

Hallo Sebastian,

ich sehe in Deinem Profil das du aus Deutschland kommst. Würde daher in deutsch schreiben.

Erstmal danke für die tolle Software. Sehr gute Arbeit.

Mir liegt allerdings eines quer im Magen:

Wenn man die Anleitung für Docker durchgeht (denke das gillt auch für lokale Installationen), wird die gallery.config.yml erstellt. Soweit so gut.

Die Extractor settings sind default in der config "Auskommentiert" (!), welches bedeutet sollte, das der Extractor deaktiviert sein sollte. Dem ist aber nicht so! Die Bilder werden an: https://api.home-gallery.org gesendet. Was dort damit passiert, ein Rätselraten ?! -> Ein absolutes No-Go.

Es findet sich zwar ein Hinweis auf https://docs.home-gallery.org/api-server/index.html, allerdings wird nicht erwähnt, das das Übermitteln an Deinem Server default eingeschaltet ist, auch wenn der extractor explizit auskommentiert ist in der config.

Ich Bitte Dich dies zu beheben, und einen auskommentierten extractor in der config entweder zu deaktivieren (wie erwartet), oder irgendwo einen "dicken" Hinweis zu hinterlassen, dass der extractor immer default eingeschaltet ist, und Bilder an Deiner URL leitet.

Viele Grüße Christian

Update import

stream.pipe Processed read directories 7 (+7)
stream.pipe Processed map to media 972 (+972)
stream.pipe Processed read directories 18 (+11)
stream.pipe Processed map to media 4014 (+3042)
stream.pipe Processed read directories 31 (+13)
stream.pipe Processed map to media 16515 (+12501)
/app/packages/database/dist/map-media.js:247
if (geoReverse.address[key]) {
^

TypeError: Cannot read property 'country' of undefined
at /app/packages/database/dist/map-media.js:247:29
at Array.forEach ()
at DestroyableTransform._transform (/app/packages/database/dist/map-media.js:246:59)
at DestroyableTransform.Transform._read (/app/node_modules/readable-stream/lib/_stream_transform.js:177:10)
at DestroyableTransform.Transform._write (/app/node_modules/readable-stream/lib/_stream_transform.js:164:83)
at doWrite (/app/node_modules/readable-stream/lib/_stream_writable.js:409:139)
at writeOrBuffer (/app/node_modules/readable-stream/lib/_stream_writable.js:398:5)
at DestroyableTransform.Writable.write (/app/node_modules/readable-stream/lib/_stream_writable.js:307:11)
at DestroyableTransform.ondata (/app/node_modules/readable-stream/lib/_stream_readable.js:681:20)
at DestroyableTransform.emit (events.js:400:28)
Error: 1

Cannot read property 'substr' of undefined while indexing

Hi,
I downloaded the binary and the git repo. in both Versions i get this error message:

index.checksum Calculating ids for 56 entries with 117.7MB of total size 117.7MB (100.0%)
/root/home-gallery/packages/index/dist/checksum.js:92
log.debug({duration: Date.now() - t0, bytes: entry.size}, Calculated id ${sha1sum.substr(0, 7)}... for ${entry.filename} with ${humanize(entry.size)} (${bps(entry.size, t0)}));
^

TypeError: Cannot read property 'substr' of undefined
at ReadStream. (/root/home-gallery/packages/index/dist/checksum.js:92:90)
at ReadStream.emit (node:events:394:28)
at emitErrorNT (node:internal/streams/destroy:157:8)
at emitErrorCloseNT (node:internal/streams/destroy:122:3)
at processTicksAndRejections (node:internal/process/task_queues:83:21)

Some feedbacks

Hi

I successfully get it running (through binary).
Some comments:

I LIKE:

  • the infinite scrolling that works very well and is reactive
  • the scan process that seems to work well comparing to other solution (librephotos typically that is damn slow on old machine)
  • video support works well

WHAT I MISS/DISLIKE (this is my opinion and to make things better, not criticism):

  • even if I start the scan process from 0, I have the following (seems to be old photos that I deleted but are still present in the database??):
    image
  • timeline missing. Ok you can choose images per year but would be nice to have some date on the side of the infinite scrolling (as are doing GPhoto, OneDrive, Apple, Plex etc) in order to 1/ jump more precisely to a date 2/know where you are
  • icons that are not always well readable:
    image
    image
  • geolocation is in german ;) (at least english would be nice):
    image
  • no way to correct / improve face recognition neither a way to see al the recognized faces
  • when I tried "edit", and tried to select 1 photo, it selects 92 photos.... so I did not try to edit anything, too risky ;)
    image
  • the geolocation feature is under used: a map with all photos in it (by cluster) would be nice
  • the object recognition is always funny, but here also we can't do anything with that. If I want to see all apple, how do I do? ;)
    image

My 2 cents :)

Help to install

Hi

As stated in an other issue, I started with docker without much success and I moved to linux binary to test the home-gallery solution.
But when I try to start the server, it exists:
pascal@NewNas:~/Home-Gallery$ ./home-gallery-latest-linux-x64 Loaded gallery configuration from gallery.config.yml ✔ Gallery main menu · server Execute: DEBUG=server* /tmp/caxa/home-gallery/1.0.1/home-gallery/node/bin/node /tmp/caxa/home-gallery/1.0.1/home-gallery/cli.js server --storage /home/pascal/.cache/home-gallery/storage --database /home/pascal/.config/home-gallery/database.db --events /home/pascal/.config/home-gallery/events.db --port 1000 Have a good day...
Any hint?
Do I have to intsall any dependencies?

thanks

Api server docker container runs on console?

Hi,

when I run the API server docker image, the server is executed in my console and not in background.

$ sudo docker run -p 3002:3000 xemle/home-gallery-api-server

Loading tensorflow and models
Load tensorflow width wasm backend in 253ms
Loading model from /app/models/mobilenet-1-100/model.json
Loaded mobilenet model in 1945ms
Loaded faceapi model in 934ms
Loading model from /app/models/coco-ssd-mobilenet_v2/model.json
Loaded coco ssd model in 8434ms
Starting server
Listen on port http://localhost:3000
Setup api routes
Server is up and running

How to run the server in background in the docker container? Or is there a different idea behind the API server?

Linux Binary use?

Hi

Can you elaborate on the way to use the binary.
I have a headless server:
if I log into ssh and launch the binary, it gets killed when I left. I can use nohup solution...and probably screen in order to come back if needed (?)
If I launch the binary in background, I have no more access to the menu.

Then, once the binary is launched, and I have new photos to scan in my library. Do I have to stop the binary and launch again choosing the right menu etc? without talking about live monitoring, is there a way to cron a scan of the library every night for example?

thanks

Address management

The way geolocations are managed in HG is very intuitive but does not fit all use cases, far from it (I am thinking of Japan, besides my own town).
I live in NYC and my photos are both geolocated in Manhattan and Brooklyn.
Unfortunately, street names are the same in both boroughs, as they were united late in the 19th c.

So, when HG writes, for example:

image

it is not very clear wether the photo is located in Brooklyn or Manhattan as there are major streets bearing that name in both boroughs.
Unfortunately, there is no way to get that information from the reverse geocoding tool you're using.
But there is a real need for improvement there.
S.

The scanner does not follow symlinks

home-gallery does not seem to detect symlinked pictures. When using a directory full of them, the scan ends almost instantly, and nothing is added to the gallery.

Feature Request: Remove Tag from Image

I deployed home-gallery yesterday, and I am enjoying it so far. While testing, I applied some arbitrary tags to some files, and have noticed that there is no way in the UI that I can find to remove a tag once it has been applied. I haven't investigated removing tags from the console yet.

Having looked through the other bugs reported here, I see you have asked for use-cases so here is one that is possibly unique.

My use case is to have a progressive webapp to load a gallery of images to share with my discord community. These images are inspirational posts created by myself and other community members to support a table-top role playing game the discord server is focused on. These images are largely generated by Midjourney AI, but may also include artist images from various locations on the internet. There are very few images taken from a digital camera.

I did see in another bug report that you recommend changing the API URL to disable the machine learning, and I think this is something I will definitely do. The images in the gallery are largely abstract and science-fantasy, and I do not want automatic organization or face recognition, and instead want to rely 100% on our community to correctly tag these images.

feature request: delete picture from database

Sometimes pictures get uploaded to the drive that are not worth publishing when viewed on the big screen.
Would be nice to have the option on the web interface to delete pictures from the database.

online docker image + docker-compose

Hi

Your projet sounds nice and I will give it a try.
Why not publishing the docker image into docker hub and proposing a docker-compose file...sounds to me easier than the steps you propose...but will give a try anyway ;)

API server adress in docker-compose

Hi

I have seen the following error in the log:

{"level":40,"time":1656358316435,"pid":286,"hostname":"6546a3b0278e","module":"extractor.apiEntry","msg":"Too many errors. Skip processing of face detection"}
{"level":40,"time":1656358316436,"pid":286,"hostname":"6546a3b0278e","module":"extractor.apiEntry","err":{"type":"Error","message":"getaddrinfo ENOTFOUND api","stack":"Error: getaddrinfo ENOTFOUND api\n    at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:71:26)","errno":-3008,"code":"ENOTFOUND","syscall":"getaddrinfo","hostname":"api"},"msg":"Could not get face detection of a044226:Pictures:Photos_canon/2020/2020-07-23 XXX/IMG_0010.JPG from URL http://api:3000/faces: Error: getaddrinfo ENOTFOUND api"}

The api:3000 is what is put in the docker-compose.yml demo file. Shouldn't be localhost:3000 ?
Or the error is coming from elsewhere?

Certificate issue?

I installed home-gallery by docker recently. I noticed geo reverse was not working properly. I got error messages from log file like this:
"level":50,"time":1664637422232,"pid":9475,"hostname":"608471ce18d3","module":"extractor.geoReverse","err":{"type":"Error","message":"ETIMEDOUT","stack":"Error: ETIMEDOUT\n at Timeout. (/app/node_modules/request/request.js:848:19)\n at listOnTimeout (internal/timers.js:557:17)\n at processTimers (internal/timers.js:500:7)","code":"ETIMEDOUT","connect":true},"msg":"Could not query geo reverse of 0e558ab *** by URL https://nominatim.openstreetmap.org/reverse?format=jsonv2...
Then I try "wget https://nominatim.openstreetmap.org/reverse?format=jsonv2..." in terminal. I got this:
Resolving nominatim.openstreetmap.org... 184.104.226.109, 2001:470:1:b3b::d
Connecting to nominatim.openstreetmap.org|184.104.226.109|:443... connected.
ERROR: cannot verify nominatim.openstreetmap.org's certificate, issued by ‘CN=R3,O=Let's Encrypt,C=US’:
Issued certificate has expired.
To connect to nominatim.openstreetmap.org insecurely, use `--no-check-certificate'.

Option to download the original file

How complicated would it be to implement a function to download the original image? If you can give me a quickstart and point me to a good entrypoint file I could also try implementing it as a PR.

PS: Thanks for this awesome project, by far the best image gallery I found (and I tried them all)

throw new ERR_HTTP_HEADERS_SENT('set');

i get the following error message:

Log
server.api.database.read Read database file /root/home-gallery/.config/home-gallery/database.db with 518 entries 61ms
server.request 200 GET / 61ms
server.request 304 GET /app.css 2ms
server.request 304 GET /App.js 1ms
server.request 200 GET /api/database?offset=0&limit=5000 64ms
server.request 206 GET /fonts/fa-solid-900.woff2 145ms
server.api.events Events file /root/home-gallery/.config/home-gallery/events.db does not exist yet. Create an event to initialize it
server.api.events Events file /root/home-gallery/.config/home-gallery/events.db does not exist yet. Create an event to initialize it
node:_http_outgoing:573
throw new ERR_HTTP_HEADERS_SENT('set');
^

Error [ERR_HTTP_HEADERS_SENT]: Cannot set headers after they are sent to the client
at new NodeError (node:internal/errors:371:5)
at ServerResponse.setHeader (node:_http_outgoing:573:11)
at ServerResponse.header (/root/home-gallery/node_modules/express/lib/response.js:771:10)
at ServerResponse.send (/root/home-gallery/node_modules/express/lib/response.js:170:12)
at ServerResponse.json (/root/home-gallery/node_modules/express/lib/response.js:267:15)
at /root/home-gallery/packages/server/dist/api/events/index.js:122:32
at Interface. (/root/home-gallery/packages/events/dist/read-events.js:47:9)
at Interface.emit (node:events:394:28)
at ReadStream.onerror (node:readline:265:10)
at ReadStream.emit (node:events:406:35) {
code: 'ERR_HTTP_HEADERS_SENT'
}
Error: 1

Steps are:

  1. run command ./gallery
  2. select "Update and process source files"
  3. select "Initial import (incremental processing)"
  4. after import finish select "start server"
  5. start browser and browse to home-gallery url
  6. crash with log from above

Support for simple keyboard shortcuts for navigating in MediaView?

First off, this is a really interesting interactive gallery application. Thanks for sharing it with the world. The browsing and exploring functionality on mobile devices (chrome and firefox on Android) is snappy and optimized for touch devices. For a library of about 40,000 items, the loading and searching speed is impressive.

When using on desktop, though, I frequently find myself getting lost when trying to return to the main listing (/) by searching for the small white fa-th grid icon or the chevrons on the left and right. Left and right swipes are fine on a mobile device, as is "back" to return to the gallery. I think the "fast" equivalent on non-mobile interfaces is single-key shortcuts. What do you think about including some simple keyboard navigation options in that view?

I've not hacked much within react, though some searching shows there may be keyboard shortcuts possible. Other javascript gallery applications I've tried lately use arrow for left and right in views, and escape to return to the index back. So maybe something like:

  • Left, Right: Navigate to previous or next
  • Escape: Return to main view grid
  • i: toggle details
  • t or z: for timeline

What do you think?

proposal: support iptc keywords

Hi, this project is awesome, thank you very much for doing it!

For me the thing that would make it perfect is for IPTC keywords to be visible and searchable.

I might be able to help with development in a small way. I've successfully built a new docker image with a small change to verify that the build is working.

feature request: add button to import pictures

Would be nice to have a button on the web interface that runs the run import --update command to add more pictures to the database.
That way pictures freshly added to the drive can be published immediately.

how is auth supposed to work?

I set a username and password but I start the app it does not prompt me for username and password when web app opens

Missing preview results in bad quality pics

I uploaded a pic that is 1328x747.
In the webapp, it's very blurry.

It's blurry because it displays the 320 preview on my fullhd monitor.
The large image is missing from the HTML and also as a preview file.

I'm not sure, but I think this is the reason:

In case of images with a width between 1280 and 1920, the web app looks for a 1920px wide preview, but this preview is not generated, because the original pic is smaller than that.

I checked the code, maybe these places cause the problem:

  1. In this file, largeSize is set to 1920:
    File: /packages/webapp/src/single/MediaViewImage.tsx
    Line: 16 -> const largeSize = width <= 1280 ? 1280 : 1920;

  2. In this file, 1920 is filtered from the preview sizes, that file is not even generated:
    File: /packages/extractor/src/image-preview.js
    Line: 66 -> const previewSizes = imagePreviewSizes.filter(s => s <= size)

If I resize my browser to 1279px, and refresh, it works well, cause then it shows the preview that is 1280px wide.

How can i make autodetect and reindex new file?

Hello, i use the home-gallery in docker compose, and my question is.

Is it possible to auto detect changes in media directory? like i upload image, and after some time it gonna show on the gallery.

Thanks :)

checksumChanges.filter is not a function

After a graceful shutdown via ctrl-c i get this error message:

Graceful shutdown. Ids of 13.1GB (3.2%) were calculated, 4.3% of 415.8GB are done. Please be patient to avoid data loss!
cli.index.update error Failed to create index: TypeError: checksumChanges.filter is not a function

Purging rendered previews

After a while, the prerender previews are not in sync anymore. Especially if you deleted some larger directories and the deleted files were removed from the database but not the cache.
Manual removal is difficult because you can not handle the structure.

The mechanism seems to work purely additive, so that the cache "storage" gets bigger and bigger, but never smaller once images or especially videos have been removed.
Only workaround right now seems to be a full rescan after removing config and storage which can last days.

Since missing files are detected and the database knows which storage items in cache exist, maybe there could be a switch that enables deleting them automatically.

error "Error: ENOENT: no such file or directory, open '/app/packages/server/dist/public/index.html'"

This is the error I'm getting with my docker install. It was working perfectly until recently. Here's the logs:

homegallery_gallery:

cli.run Starting server
cli.task.run Execute: /usr/local/bin/node /app/gallery.js --log-level info --log-file /data/config/gallery.log --log-file-level debug server --storage /data/storage --database /data/config/database.db --events /data/config/events.db
server Open Home Gallery on http://localhost:3000
cli.server Server started. Open it at http://localhost:3000
server.api.database.read Read database file /data/config/database.db with 29685 entries
server.api.events Read events file /data/config/events.db with 1 events
server.webapp error Could not read index file /app/packages/server/dist/public/index.html
server.request warn 404 GET / 21ms

homegallery_api:

Loading tensorflow and models
2022-12-01 15:11:30.996352: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
Load tensorflow width node backend in 280ms
Loading model from /app/models/mobilenet-1-100/model.json
Loaded mobilenet model in 349ms
Loaded faceapi model in 332ms
Loading model from /app/models/coco-ssd-mobilenet_v2/model.json
Loaded coco ssd model in 1090ms
Starting server
Listen on port http://localhost:3000
Setup api routes
Server is up and running

Here's my docker_compose.yml:

version: "3.9"
services:
api:
# custom build via
#build: packages/api-server
image: xemle/home-gallery-api-server
environment:
# TensorflowJS backends
# - cpu: slowest and best support
# - wasm: good perfromance for arm64 and amd64 platforms
# - node: best performance on amd64 platform
#- BACKEND=cpu
#- BACKEND=wasm
- BACKEND=node
gallery:
# custom build via
#build: .
image: xemle/home-gallery
environment:
- GALLERY_API_SERVER=http://api:3000
#- GALLERY_API_SERVER_CONCURRENT=1 # On low powered devices
#- GALLERY_API_SERVER_TIMEOUT=60 # On low powered devices
- GALLERY_OPEN_BROWSER=false
volumes:
- ./data:/data
# Mount your media directories below /data
- /docker/homegallery/data/Pictures:/data/Pictures
ports:
- "4000:3000"
user: "${CURRENT_USER}"
entrypoint: ['node', '/app/gallery.js']
command: ['run', 'server']

I tried rebuilding, ensuring mounts are fully accessible, etc...

One thing I see in the container itself, is that the /app/packages/server/dist/public directoy doesn't exist. The dir /app/packages/server/dist/ does though.

Thanks in advance for any advice.

[practical question] Is there a way to automatically refresh the database when adding images?

Here is the workflow I am currently using, which I find a bit awkward:

  1. I add photos to the main directory
  2. I open Portainer, change the default shell to /bin/ash and go to the Console of the HG stack
  3. I execute /app/gallery.js run import --update as root

Am I missing something? Wouldn't it be more practical to add a refresh button somewhere in the GUI?
NB. I also tried to change the stack docker-compose.yml file and add the instruction as an opening command but it did not work.

Cannot find module '/tmp/.../logger/dist/index.js

Hello, thank you for home gallery. I love it so far.

It has run for a while without problems. But now, after restarting my server, I can't get home gallery run.
No matter what command I enter, it says that it can't find a temporary file.

mini@m:~/homegallery$ ./home-gallery-latest-linux-x64 
node:internal/modules/cjs/loader:361
      throw err;
      ^

Error: Cannot find module '/tmp/caxa/home-gallery/1.6.1/home-gallery/node_modules/@home-gallery/logger/dist/index.js'. Please verify that the package.json has a valid "main" entry
    at tryPackage (node:internal/modules/cjs/loader:353:19)
    at Function.Module._findPath (node:internal/modules/cjs/loader:566:18)
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:919:27)
    at Function.Module._load (node:internal/modules/cjs/loader:778:27)
    at Module.require (node:internal/modules/cjs/loader:1005:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at Object.<anonymous> (/tmp/caxa/home-gallery/1.6.1/home-gallery/gallery.js:3:16)
    at Module._compile (node:internal/modules/cjs/loader:1105:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1159:10)
    at Module.load (node:internal/modules/cjs/loader:981:32) {
  code: 'MODULE_NOT_FOUND',
  path: '/tmp/caxa/home-gallery/1.6.1/home-gallery/node_modules/@home-gallery/logger/package.json',
  requestPath: '@home-gallery/logger'
}

Parallelizing imports

I've really enjoyed using your project, thanks for sharing it! Definitely the most responsive photo gallery I've used so far 🙂

I noticed that the import process is currently single threaded. Is there any reason why it couldn't be parallelized across multiple threads? There's a worker_threads API that looks interesting, I haven't used it before: https://nodejs.org/docs/latest-v14.x/api/worker_threads.html

no arm support?

just to verify, there does not seem to be arm v7 support? i thought there would be, because you mention raspberry pi several times in your documentation

No items in gallery, after importing

I ran:

/app/gallery.js run init --source /data/Pictures
/app/gallery.js run import --update

and yet, still, the pages are all blank:
image

How can I help?

Feature Request: option to directly serve images

With large libraries (mine has about 1.5 million files) the compressed pictures take a huge amount of disk space. I thought using a dedicated disk would be a good idea, so I hooked up a 500GB disk to my server... But it was completely filled up after scanning ~500'000 images!
Knowing that my collection is 1.2TB big, the compressed pics would probably take up more space than the originals after a full scan...

It would be awesome if home-gallery could serve the original images themselves and not a compressed copy, or to compress them on the fly as they're requested, then delete them after a while.

Timeline / Filter by month

Any thoughts on implementing the possibility to filter not only by year, but also by month?
Also it would be awesome to have a "timeline scrollbar" like the one in Google Photos (but honestly not really an idea how to do that efficiently)

Help for some debug

Hi

I came back to Home Gallery to see the progress made.
I updated the docker image and remove all previous database. I did an import --update but I lost the terminal connection during the process after few hours.
So I did import --update again and here is the output:

$ docker-compose exec gallery /app/gallery.js run import --update
cli.run Import online sources from: /data/Pictures
cli.task.run Execute: /usr/local/bin/node /app/gallery.js --log-level info --log-file /data/config/gallery.log --log-file-level debug index --directory /data/Pictures --index /data/config/Pictures.idx --exclude-if-present .galleryignore --journal 0626-iKTZ
index Updating file index for directory /data/Pictures
index.create Read 40445 files in /data/Pictures 15:59
index.merge Merged 40445 entries 20s
index.update No changes found 03:38
index.journal Journal /data/config/Pictures.idx.0626-iKTZ.journal created
index Updated file index for directory /data/Pictures 21:23
cli.task.run Execute: /usr/local/bin/node /app/gallery.js --log-level info --log-file /data/config/gallery.log --log-file-level debug extract --index /data/config/Pictures.idx --storage /data/storage --journal 0626-iKTZ
extractor.image.resize Use sharp to resize images
index.readStream Reading file index journal /data/config/Pictures.idx.0626-iKTZ.journal
cli.extract Extract all meta data and calculated all preview files from 0 entries 53s
cli.task.run Execute: /usr/local/bin/node --max-old-space-size=2048 /app/gallery.js --log-level info --log-file /data/config/gallery.log --log-file-level debug database --index /data/config/Pictures.idx --journal 0626-iKTZ --storage /data/storage --database /data/config/database.db
index.readStream Reading file index journal /data/config/Pictures.idx.0626-iKTZ.journal
database.build Created 0 database entries 6.2s
database.mergeJournal Read file index journal /data/config/Pictures.idx.0626-iKTZ.journal
cli.database Database unchanged: Error: Journals contain no changes
cli.task.run Execute: /usr/local/bin/node /app/gallery.js --log-level info --log-file /data/config/gallery.log --log-file-level debug index journal --index /data/config/Pictures.idx --journal 0626-iKTZ -r
index.journal Remove journal 0626-iKTZ from file index /data/config/Pictures.idx
cli.run Have a good day...

On website side, I have no photos at all:
image

Any hints?
Thanks

import -i crashed

after days import with -i flag. process stopped by this error message:

TypeError: Cannot read property 'toFixed' of undefined
at FfmpegCommand. (/app/packages/extractor/dist/video.js:55:94)
at FfmpegCommand.emit (events.js:400:28)
at Object.extractProgress (/app/node_modules/fluent-ffmpeg/lib/utils.js:345:15)
at /app/node_modules/fluent-ffmpeg/lib/processor.js:529:23
at /app/node_modules/fluent-ffmpeg/lib/utils.js:387:34
at Array.forEach ()
at emit (/app/node_modules/fluent-ffmpeg/lib/utils.js:387:11)
at /app/node_modules/fluent-ffmpeg/lib/utils.js:419:13
at Array.forEach ()
at Object.append (/app/node_modules/fluent-ffmpeg/lib/utils.js:418:20)
cli.run error Error: 7 462505:22:23

Images are missing after initial import, API is disabled

Running in docker-compose on Debian 11.4 x86_64

I disabled the API in docker-compose, and modified the API URL as per the comment here:
#37 (comment)

I also removed the volume data from my first indexing, and started importing the photo archive fresh. The import is a lot faster without the API, however most of my images have broken URIs for the thumbs and full sized images, as can be seen in the attachment.

I checked in incognito mode, to ensure this isn't a caching problem and I have the same results. Is there a way to regenerate all of the thumbnails, or do you have advice on how I can resolve this issue?

image

Missing timeline to jump in time

Hello

As said previously here #6 , your gallery is really nicely done and one of the best I have tested so far (I tested all of them! :) ).
It is really fast with slick design with infinite scrolling which most of the others failed to do.
Yet, in my opinion, a major element is missing: the capability to jump in time easily.

You would need a side timeline, plus some time in the photo stream (year/month)
Google photo, Onedrive and others big ones are providing it and it is missing to Home Gallery.

Google photo screenshot:
image

Onedrive screenshot:
20220628_135532000_iOS

Docker Compose Issue

When I run the Compose provided, I get the following error

services.gallery.expose is invalid: should be of the format 'PORT[/PROTOCOL]' : exit status 1

Docker image for linux/arm/v7 broken

Hi! I'm trying to start the server and the api via docker-compose on my raspberry pi 4, but docker seems to have some problems:

Pulling api (xemle/home-gallery-api-server:dc9de695)...
latest: Pulling from xemle/home-gallery-api-server
ERROR: no matching manifest for linux/arm/v7 in the manifest list entries

docker --version
Docker version 20.10.7, build f0df350

docker-compose.yml

version: "3.9"
services:
  api:
    image: xemle/home-gallery-api-server
    environment:
      # TensorflowJS backends: cpu, wasm and node. Use wasm
      # if you have troubles.
      #- BACKEND=cpu
      - BACKEND=wasm
      #- BACKEND=node
    ports:
      - "3000"
  gallery:
    image: xemle/home-gallery
    environment:
      - GALLERY_API_SERVER=http://api:3000
    volumes:
      - ./data:/data
      # Mount your media directories below /data
      - ${HOME}/Pictures:/data/Pictures
    ports:
      - "3000:3000"
    user: "1000:1000"
    entrypoint: ['node', '/app/gallery.js', 'run', 'server']

thanks in advance!

Issues with static export: Edit is possible and lots of API calls?

Hi! I would love to use home-gallery for a public photo gallery.

However, after fiddling for like an hour, I cannot get the export working as expected. There are two issues:

  • No matter which settings I change, the static export always shows the "Edit" functionality. When visiting your demo, there is no such edit button. How do I get rid of it?
  • When clicking any image, the site sends requests to /api/events.json and /api/events/stream, which all fail because there is no such directory in the export. I have found some places in the documentation where events are mentioned, but without any details about generation or how to enable/disable them.

If I can post any more details, please let me know. I am using the Docker image to generate the database and images, and to export the static files.

Search tags in the Tags page

Fisrt, let me tell you how much I like HomeGallery: fast, lightweight -- the perfect complement to heavier solutions like digiKam or PhotoPrism.
I have tagged my photo assets with a lot of tags in digiKam and they are well recognized by HG.
But, due to their number, the Tags page becomes difficult to use.

What would help: a search box reducing the number of tags displayed when input.
A much better solution than the standard search box of the browser IMO as that one only selects the tags in the long list.

Feature Request: Integration with Nextcloud

Hi,

What an impressive job as a side project! Really.

Would you thing it's doable (time/cost reasonable) to link/point the storage with a Nextcloud instance? Taking advantage of NC's mobile apps, synchronization feature and so on, but with the power of Homegallery.

Do you already have a straightforward hack to do that (docker image bridge, script, etc.)?

What do you think of bridging Homegallery natively with Nextcloud as an integrated app (https://nextcloud.com/developer/)?

If neither of these approaches is to your liking, what solution would you propose to quickly and efficiently link the two applications?

[optimization] Allow to disable face and object recognition altogether

In order to optimize the discovery of new photos in the registered folder, is there an environment variable thatg allows to disable face and object recognition?
I know I am not using HG the most mainstream way (I only manage monument and cityscape photos with it) but I guess it would also be useful for otherf users. Besides PhotoPrism has such an option.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.