# Web-based Photo Management



## Steffen (Jul 9, 2021)

Hello,

I hope such such a question is ok in this forum.

I am looking for a web-based photo management port, working on images without importing them and with face and object recognition.

Tools like Photoprism (https://github.com/photoprism/photoprism) or Photonix (https://github.com/photonixapp/photonix) would be perfect. 

However, they depend on Tensorflow or Docker, both are not well or not working on FreeBSD.

There is an unofficial port for Photoprism but Tensorflow prevents the build as it needs some ugly patching (https://docs.photoprism.org/getting-started/advanced/freebsd/).

Do you know any working alternatives for FreeBSD?

Thanks,

Steffen


----------



## drhowarddrfine (Jul 9, 2021)

Your link to photoprism says it works and I don't see any ugly patching involved. It looks really easy.


----------



## Steffen (Jul 9, 2021)

I tried it and it doesn't. There is a patch for Tensorflow in the port but that is not working. It is the same problem py-tensorflow has, see https://github.com/huo-ju/photoprism-freebsd-port/issues/13

As I read the thread I see that today a fixed version of science/py-tensorflow landed in  the tree. So maybe you are right and I will give it a try.

But still, it is an unofficial port by someone from the internet[TM]. So my question is still valid: Are there any alternatives?


----------



## rootbert (Jul 9, 2021)

there it is: https://piwigo.org/ https://mediagoblin.org/ https://lychee.electerious.com/ https://github.com/LibrePhotos/librephotos https://pixelfed.org/


----------



## Steffen (Jul 9, 2021)

1. Piwigo imports files and has no object recognition.
2. Mediagoblin is a publishing platform.
3. Lychee imports files.
4. Librephotos uses Docker and is not in the ports.
5. Pixelfed has no features I was asking for.

Don't get me wrong, but have you read my initial posting?

BR,
Steffen


----------



## rootbert (Jul 9, 2021)

oh, sorry , I have probably missed the most important part


----------



## Jose (Jul 9, 2021)

Steffen said:


> There is an unofficial port for Photoprism but Tensorflow prevents the build as it needs some ugly patching (https://docs.photoprism.org/getting-started/advanced/freebsd/).


Looks like the patches are only needed for Freebsd 11








						photoprism-freebsd-port/Makefile at 5a6019d3bb978ec41b064d1aa00bcd13be50e1e9 · huo-ju/photoprism-freebsd-port
					

The photoprism port for FreeBSD. Contribute to huo-ju/photoprism-freebsd-port development by creating an account on GitHub.




					github.com


----------



## Steffen (Jul 9, 2021)

Jose said:


> Looks like the patches are only needed for Freebsd 11
> 
> 
> 
> ...


Sorry, I missed some info (well, I asked for other solutions but there is probably none  ) 

With "ugly patching" I meant the problem with two zlibs, see https://github.com/huo-ju/photoprism-freebsd-port/issues/1#issuecomment-781193830 The issue is closed but it is still a thing.


----------



## Steffen (Jul 10, 2021)

Good news: With a working science/py-tensorflow photoprism takes a huge step onto FreeBSD https://github.com/huo-ju/photoprism-freebsd-port/issues/13


----------



## D-FENS (Dec 12, 2021)

I can report successful installation of Photoprism on *FreeBSD 13.0-RELEASE-p4* in a jail (setting up jails as described in the handbook, I recommend using sysutils/iocage) using the procedure below.
System parameters: KVM/qemu VM with *32 GB RAM* and *24 CPU threads*. Compile time *~30 min*.
I got strange VM crashes when I tried to compile on 16 GB RAM, but I am not sure the RAM size was the reason. We need more testing.

```
jls
jexec 1  # where 1 is my jail's JID

# The following is executed inside the jail:

pkg install ffmpeg p5-Image-ExifTool bash bazel029 git gmake go npm wget
portsnap fetch extract     # or "fetch update" if the ports tree is already installed

cd /tmp
fetch https://github.com/huo-ju/photoprism-freebsd-port/archive/refs/heads/main.zip
unzip main.zip
cd photoprism-freebsd-port-main

make config
# I selected only AVX instruction set, no CUDA.

# The next command takes a very long time to complete...
make
make install

# This directory had wrong permissions, it belonged to root and had to be modified:
chown -R photoprism:photoprism /var/db/photoprism/storage

sysrc photoprism_enable="YES"
sysrc photoprism_assetspath="/var/db/photoprism/assets"
sysrc photoprism_storagepath="/var/db/photoprism/storage"

photoprism --assets-path=/var/db/photoprism/assets --storage-path=/var/db/photoprism/storage --originals-path=/var/db/photoprism/storage/originals --import-path=/var/db/photoprism/storage/import passwd
# Enter your password when prompted

service photoprism start
```
The service is available at the jail's address on port *2342*.


----------

