Skip to main content

Web-camera based watermeter for Juham

Project description

Watermeter plugin for Juham™

Description

A web camera and AI-based water meter solution for Juham™ home automation.

This package includes two different water meter implementations:

  • A simple class that compares subsequent images to measure differences. The greater the difference between images, the more the arrows and digits on the water meter have changed, indicating water consumption. This solution also uploads the images to a specified FTP site when water consumption is detected, allowing homeowners to inspect the water meter visually. While this solution doesn’t provide exact water consumption readings, it is highly reliable for detecting leaks. Just ensure that spiders or other potentially moving objects don't obstruct the camera's view of the water meter.

  • Tesseract OCR and OpenCV solution for reading and interpreting water meter digits. This class requires further work to be truly useful. My Raspberry Pi didn't have enough disk space, so I decided to set this aside for now.

.. image:: _static/images/watermeter_diff.png :alt: Web camera based water meter leak detector based on comparison of subsequent images :width: 640px :align: center

Getting Started

To install:

.. code-block:: bash

  pip install juham-watermeter

Which installs everything needed for reading water meters with the simple image comparison based solution.

If you want to play with the Tesseract OCR and OpenCV solution for reading and interpreting water meter digits, please read on.

Installing Tesseract OCR to read the digits:

.. code-block:: bash

  sudo apt install tesseract-ocr

If you are on Windows, visit the Tesseract GitHub repository, or Download a precompiled Windows binary from UB Mannheim.

  1. Install

    .. code-block:: bash

    pip install juham-watermeter

  2. Configure

To adjust update interval and other attributes edit WaterMeter.json configuration file.

Note about OpenCV and contributors

The Python coverage failed with the No source for code: 'juham_watermeter\config-3.py' error, when all the other Python projects with precisely identical structures worked fine. Traced down the bug to opencv package, and added a .coveragerc file with the following content:

.. code-block:: bash

[run]
omit = 
  config.py
  config-3.py

as a solution. This will of course blow up sooner or later, when some OpenCV developer decides to rename those files.

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

juham_watermeter-0.0.8.tar.gz (16.4 kB view details)

Uploaded Source

Built Distribution

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

juham_watermeter-0.0.8-py3-none-any.whl (16.8 kB view details)

Uploaded Python 3

File details

Details for the file juham_watermeter-0.0.8.tar.gz.

File metadata

  • Download URL: juham_watermeter-0.0.8.tar.gz
  • Upload date:
  • Size: 16.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.10

File hashes

Hashes for juham_watermeter-0.0.8.tar.gz
Algorithm Hash digest
SHA256 1d08e65e7a9baf0a03c7d8eafc1d42e20dded870cf18c8c9156cc49ec25ae5cf
MD5 9b69990f6d166f4961f6fa921ea5f7f6
BLAKE2b-256 d256f0cd08521ebbf685af8f2e8b1559f5d0cf3c0dea799d2cd9e316999baf66

See more details on using hashes here.

File details

Details for the file juham_watermeter-0.0.8-py3-none-any.whl.

File metadata

File hashes

Hashes for juham_watermeter-0.0.8-py3-none-any.whl
Algorithm Hash digest
SHA256 ca6bfa77f4edc32f117d826edbf9bae50337b784ed023835f7664c733e3e24b3
MD5 361d461826ddb21ff70fea921afe8f1d
BLAKE2b-256 ec9c57ec0ec6b2843b13a07bb64a368652d4f8fae0f232c416ff26d8cd74ae2e

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