ozonebase icon indicating copy to clipboard operation
ozonebase copied to clipboard

Description on how to use the images ozonedev and ozonedemo

Open lucasnathan opened this issue 8 years ago • 2 comments

I tried to run the examples through the docker images: https://hub.docker.com/u/web2wire/

However, I wasn't able to reproduce the same results of the page: http://demo.ozone.network:9280/demo.html

Step-by-step this is what I did:

$ docker pull web2wire/ozonedev $ docker run -it web2wire/ozonedev /bin/bash container$ ./bootstrap-ozone.sh container$ cd demo container$ ./run-demo.sh

and this was the output:

2016-12-13 17:56:48,791 CRIT Set uid to user 1000
2016-12-13 17:56:48,799 INFO RPC interface 'supervisor' initialized
2016-12-13 17:56:48,799 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2016-12-13 17:56:48,799 INFO supervisord started with pid 96
2016-12-13 17:56:49,802 INFO spawned: 'app' with pid 99
2016-12-13 17:56:49,803 INFO spawned: 'schedule' with pid 100
2016-12-13 17:56:49,881 INFO exited: app (exit status 1; not expected)
2016-12-13 17:56:50,883 INFO spawned: 'app' with pid 115
2016-12-13 17:56:50,884 INFO success: schedule entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2016-12-13 17:56:50,957 INFO exited: app (exit status 1; not expected)
2016-12-13 17:56:52,959 INFO spawned: 'app' with pid 120
2016-12-13 17:56:53,037 INFO exited: app (exit status 1; not expected)
2016-12-13 17:56:56,040 INFO spawned: 'app' with pid 125
2016-12-13 17:56:56,110 INFO exited: app (exit status 1; not expected)
2016-12-13 17:56:57,111 INFO gave up: app entered FATAL state, too many start retries too quickly

I notice the files on /ozonebase/server/src/examples/ but I'm not sure how to access starter_example.html from my host browser...

I hope someone can assist me on solving this, so I can be able to try oZone

lucasnathan avatar Dec 13 '16 18:12 lucasnathan

(This is holiday time, so responses may be delayed - sorry about that)

Lets break this into two parts: a) Getting the environment working b) Starting to use the examples

Once you resolve a) we can focus on b)

As far as a) goes, there are two ways. The docker way (easiest) or the build your own way. I don't use docker, so lets wait for @web2wire to respond.

As far as build your own is concerned, I just built ozone from scratch on two different ubuntu machines. I committed some changes that were causing issues (but not the ones you emailed about FFMPEG). If you follow the install instructions exactly it should work without problems (ozone uses a specific version of ffmpeg, so for now its best you don't try and integrate with your OS bundled ffmpeg)

pliablepixels avatar Dec 13 '16 23:12 pliablepixels

My first suggestion would be to run the commands in the run-demo script manually to start with.

So start with setting the environment

export DBG_PRINT=0
export DBG_LEVEL=0
export DBG_LOG=
#
# Motion detection config
#
export OZ_OPT_MOTION_debug_streams=true
export OZ_OPT_MOTION_debug_images=false
export OZ_OPT_MOTION_debug_location="/tmp"
export OZ_OPT_MOTION_options_refBlend=7
export OZ_OPT_MOTION_options_varBlend=9
export OZ_OPT_MOTION_options_blendAlarmedImages=true
export OZ_OPT_MOTION_options_deltaCorrection=false
export OZ_OPT_MOTION_options_analysisScale=1
#export OZ_OPT_MOTION_zone_default_color=(Rgb)RGB_RED
export OZ_OPT_MOTION_zone_default_checkBlobs=true
export OZ_OPT_MOTION_zone_default_diffThres=1.0
# Unused - xport OZ_OPT_MOTION_zone_default_scoreThres=1.41
# Unused - export OZ_OPT_MOTION_zone_default_scoreBlend=64
export OZ_OPT_MOTION_zone_default_alarmPercent_min=0.5
export OZ_OPT_MOTION_zone_default_alarmPercent_max=0.0
export OZ_OPT_MOTION_zone_default_score_min=50
export OZ_OPT_MOTION_zone_default_score_max=0

And then run the two commands that supervisord runs, but do them manually. The commands are

/usr/bin/nodejs demo.js

to start the web side and

/home/ozone/install/bin/starter_example

to start the server side. So lets see what issues either of them returns with.

web2wire avatar Dec 14 '16 12:12 web2wire