ethoscope.web_utils package

Submodules

ethoscope.web_utils.control_thread module

class ethoscope.web_utils.control_thread.ControlThread(machine_id, name, version, ethoscope_dir, data=None, *args, **kwargs)[source]

Bases: threading.Thread

The versatile control thread From this thread, the PI passes option to the node. Note: Options are passed and shown only if the remote class contains a “_description” field!

info
k = 'roi_builder'
run()[source]
set_evanescent(value=True)[source]
stop(error=None)[source]
classmethod user_options()[source]
was_interrupted
class ethoscope.web_utils.control_thread.ExperimentalInformations(name='', location='', code='')[source]

Bases: ethoscope.utils.description.DescribedObject

info_dic

ethoscope.web_utils.helpers module

ethoscope.web_utils.helpers.cpu_serial()[source]

on a rPI, return a unique identifier of the CPU

ethoscope.web_utils.helpers.file_in_dir_r(file, dir)[source]
ethoscope.web_utils.helpers.get_commit_version(commit)[source]
ethoscope.web_utils.helpers.get_machine_info(path)[source]

Reads the machine NAME file and returns the value.

ethoscope.web_utils.helpers.get_version()[source]
ethoscope.web_utils.helpers.isMachinePI()[source]

Return True if we are running on a Pi - proper ethoscope

ethoscope.web_utils.helpers.pi_version()[source]

Detect the version of the Raspberry Pi. Returns either 1, 2 or None depending on if it’s a Raspberry Pi 1 (model A, B, A+, B+), Raspberry Pi 2 (model B+), Raspberry Pi 3 or not a Raspberry Pi.

ethoscope.web_utils.record module

class ethoscope.web_utils.record.ControlThreadVideoRecording(machine_id, name, version, ethoscope_dir, data=None, *args, **kwargs)[source]

Bases: ethoscope.web_utils.control_thread.ControlThread

k = 'experimental_info'
run()[source]
stop(error=None)[source]
class ethoscope.web_utils.record.GeneralVideoRecorder(video_prefix, video_dir, img_path, width=1280, height=960, fps=25, bitrate=200000)[source]

Bases: ethoscope.utils.description.DescribedObject

run()[source]
stop()[source]
class ethoscope.web_utils.record.HDVideoRecorder(video_prefix, video_dir, img_path)[source]

Bases: ethoscope.web_utils.record.GeneralVideoRecorder

class ethoscope.web_utils.record.PiCameraProcess(stop_queue, video_prefix, video_root_dir, img_path, width, height, fps, bitrate)[source]

Bases: multiprocessing.process.Process

run()[source]
class ethoscope.web_utils.record.StandardVideoRecorder(video_prefix, video_dir, img_path)[source]

Bases: ethoscope.web_utils.record.GeneralVideoRecorder

Module contents