Home Surveillance System (HSS)

Ha, ha - join the club of people using 'projects' - you will never look back (I'm sure).

You can always create another project - with a GOOD name and then delete the previous one.

Only takes a couple of "go's" before you become an expert!!

1 Like

@wb666greene Actually it is even easier to clone a project.

  1. go to the hamburger menu (top right) and select export
  2. select all flows and Copy to clipboard
  3. go to the hamburger menu and select Projects => New
  4. fill in the info for the new project and hit Create Project
  5. go to the hamburger menu and select import
  6. paste the flow in and deploy it.

You have now made a copy of the project.

2 Likes

I'm having trouble deleting the original after I've cloned it. Maybe it my node-red 1.3.1 version? I updated to this system to match what @krambriw said his HSS was running on. I've no real objection to updating.

Stability of HSS with the default public feeds has been exceptional! I hope to find time tonight to try rtsp streams from my IP cameras, using Walter's suggestions posted above.

Once you have created a new project, go to the projects again and select open. At that point you should be able to select the old project and a trash can icon should appear on the right side of that project. Click it and you can delete the old project.

1 Like

Coming back to this, I have modified my own HSS version a bit so that it supports both the internal default using the tf-coco-ssd node as well as relaying the image data out to an external AI system. In my case I have an external Python script that is using yolov4. It seems to work fine and I will publish more details about this, just have to participate in a meeting starting now

Continuing this posting...just mentioning this is for ip cameras only right now

When you trigger the object detection (via an IR detector or similar) you do that by sending a message using the link in node for the selected camera (see screenshot below as example for CAM10)

If you want to use the default object detection, the msg.payload should just be a boolean true.

If you want to use your external AI system, the message shall in addition also have the property msg.ext_object_det set to boolean true. What will then happen is that the image data will be sent out to your MQTT broker on topic object_det/camx which in this example would be object_det/cam10

Your AI system should subscribe to the topic object_det/# and when image data is recieved, process it for object detection. If found, then publish the annotated image data to the topic object_res/camx where camx is cam10 in this example

This is how the modified sub-flow currently looks like

Resulting annotated image sent via Telegram

Having successfully installed HSS (v1.1.0) yesterday, everything appears to be working other than thumb nails on the snap shot and show recordings screens, I just get blank screens with the file name, is it correct ? I assumed I would see thumb nails of the recording etc any ideas ?

image

Did you re-run Step 1 and Step 2 in HSS Setup SAS tab-flow (after you installed v1.1.0) ??
In v1.1.0 is a new version of our organise script that removes _sfpg_data as Single File Gallery 4.8.0 stores the thumbnails in a different format (now).

See thread number #72 Home Surveillance System (HSS) - #72 by dynamicdave

If @dynamicdave suggestion does not work, go to a terminal widow and run:
sudo apt instal php7.3-gd
and see if that fixes it.

1 Like

I didn't install a previous version, this was a new installation yesterday, I followed the instruction so therefore Step1 and Step2 have been done, and yes I understand thread #72 I read all the threads prior to downloading, here is the info from ..... /var/www/html/hss_media/snapshots/index.php

	Single File PHP Gallery 4.8.0 (SFPG)

	See EULA in readme.txt for commercial use
	See readme.txt for configuration

	Released: 28-sep-2021
	http://sye.dk/sfpg/
	by Kenny Svalgaard

Ok thanks @zenofmud sudo apt install php7.3-gd worked and all is working now.

Really pleased you have got it working with help from @zenofmud Hope you enjoy using HSS.

EDIT: You may find you also need to install the GD library in PHP to get thumbnails to appear.
sudo apt install php7.3-gd

I too can verify that:
sudo apt install php7.3-gd
fixed it for my HSS v1.1.0 system installed as an update via new project.

Unfortunately I seem to have triggered an issue. I was displaying Camera-1 in the main window and chose "show snapshots" in the drop-down below the main window (or it could have been in the drop-down below the top-left thumbnail can't really be sure). I verified that I wasn't getting thumbnails. I then did the apt-get install and lo the thumbnails appeared, even for the snapshots I'd taken with the initial v0.55.1 version. Problem is I can't get back to displaying Camera-1.

Unlike when the one of the streams drops out in the small windows clicking Presets again doesn't fix it. If I choose Camera-2 in the small window drop-down Camera-2 displays and if I click the small window the camera-2 stream appears in the main window.

Re-choosing Camera-1 returns the small display to show "Mirror to main display" with a "broken document" icon

One step forward one step back.

I look forward to this, as I recall we have very different design philosophies, I do round-robin processing of frames from multiple IP camera streams so my i7 "mini PC" system with Coral TPU ~40fps throughput is shared as equally as possible amoung my 14 cameras (I'm not saturating the TPU, I've saturated the python OpenCV ability to feed the AI inference queue, on a much more expensive i7 with more cores I've been able to hit ~70 fps which is pretty much every frame from every camera (each camera was 5 fps for this test, 7 were 4k, 7 were 1080p).

As I recall you use traditional "motion detection" to detect frames or regions within frames to send to the AI inference. I see this as the only option for yolov4 as I can't get better than about 6 fps with the yolo models I've tried. I've found the "tiny yolo" variations are not as good as MobilenetSSDv2_coco in terms of false detections, at least with my outdoor facing cameras. I've got a 600x600 image full yolo model running on my Nano that can do ~4fps, its on my ToDo list to pipe my current detections to this as a final verification, but my current system has had a low enough false alarm rate (~1 in 30 million frames, usually transient bugs, spiders, birds etc.) that its priority has dropped dramatically and I've moved on to other projects.

I already have implemented "virtual MQTT cameras" where snapshot frames can be sent via MQTT and processed same as an RSTP or HTTP snapshot stream. unfortunately the Pi4 Networking layer chokes on this with 4K cameras.

I think the popularity of HSS has exceeded the limit on some of the 'free' cameras, and clearly this is one of them. I'm hoping to get some more camera feeds from our active users.

The camera-1 feed is working now, it was not a video source problem, I could have any of the other three small displays show the camera-1 feed and then "mirror" it to the main display.

I restored it by going to the HSS Initialization tab and clicking the "load hss basic config.txt" inject node again.

I can repeat the problem:

  1. Choose Show Snapshots from the main window drop-down
  2. Look at a few images (may or may not be necessary, but its what I did)
    3)Click the Camera-1 small window and instead of the video, the main window displays "click for snapshot"

Reloading the config file fixes it. How are you supposed to exit "Show Snapshots"?

What is perhaps strange is if I view camera-4 in the main window and choose show snapshots I can view them and click camera-4 small window and return camera-4 to the main window by clicking the small camera-4 window, but if I click the small camera-1 window I get "click for snapshot in the main window but the other three small windows still function as expected.

It seems totally repeatable after I re-read the config.txt file.

Just select one of the cameras in the dropdown or click on a small camera window. You may have to wait a bit for the video feed to start up again but it should show if you wait a bit.

What model Pi are you using and what is the feed url?.
Using a Pi3 and the default URL's it takes me 2+ seconds for the main monitor to bring up the image.

Note, this pi is not running thing else....

That is the "bug" I've stumbled upon. It works when camera-2 3 or 4 is is clicked int he small windows when I chose show snapshots to return, but when camera-1 is clicked in the small window "click for snapshot" is displayed in the main window.

I'm used to camera connection lags some of my 4K camera take as long as 12 seconds to open an rtsp connection.

I am running HSS on a Pi4B 2GB.

I see the same thing, when I'm in snapshots and I click on any of the small monitors, I get the 'Click for Snapshot'

That comes from the <img...> statement for the main monitor
<img src={{msg.url}}?{{msg._msgid}} class="main_monitor" ng-click="send({payload:action('snapshot?mainview_url'), topic:'Snapshot'})" title="Click for snapshot">
and is displayed when you hover over the image so you know you can click and get a snapshot.

I have been successful getting a feed from a rtsp camera's into HSS but I am seeing a 7 second delay when I compare it to the same feed from the following flow which I have on a separate pi (both are pi4 2gb)


this flow uses ..
ffmpeg -i rtsp://192.168.0.94:554/user=++++_password=++++_channel=1_stream=1.sdp?real_stream -an -c:v copy -f mp4 -movflags +frag_keyframe+empty_moov+default_base_moof pipe:1";

compared to the HSS flow ....
{"command":"start","args":["-loglevel","error","-nostats","-f","rtsp","-rtsp_transport","tcp","-re","-i","rtsp://192.168.0.94:554/user=++++_password=++++_channel=1_stream=1.sdp?real_stream","-c:v","copy","-c:a","aac","-f","mp4","-movflags","+frag_keyframe+empty_moov+default_base_moof","pipe:1","-progress","pipe:3"]}

Would you say something is wrong with the HSS command or is it the nature of HSS code that's slowing it down ? I mean I just had a delivery from Amazon the guy rang the door bell but according to HSS he was only halfway up my drive.

HSS is doing nothing to deliberately slow things down. You can try the same command as you have in your other flow and see if it improves. The command in HSS is just an example. The command "args" are just those that ffmpeg "understands", just that we are using the ffmpeg-spawn node. I would suggest you try a command like this:

{"command":"start","args":["-i","rtsp://192.168.0.94:554/user=++++_password=++++_channel=1_stream=1.sdp?real_stream","-c:v","copy","-c:a","aac","-f","mp4","-movflags","+frag_keyframe+empty_moov+default_base_moof","pipe:1"]}