From 299fa2c8cfb256b4df7882b19ced5ab1319f7819 Mon Sep 17 00:00:00 2001 From: Théo de la Hogue Date: Mon, 29 Jan 2024 17:12:20 +0100 Subject: Improving logging documentation. --- docs/user_guide/gaze_analysis_pipeline/logging.md | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) (limited to 'docs/user_guide') diff --git a/docs/user_guide/gaze_analysis_pipeline/logging.md b/docs/user_guide/gaze_analysis_pipeline/logging.md index c5fe15a..617690f 100644 --- a/docs/user_guide/gaze_analysis_pipeline/logging.md +++ b/docs/user_guide/gaze_analysis_pipeline/logging.md @@ -35,15 +35,15 @@ from argaze.utils import UtilsFeatures class ScanPathAnalysisLogger(DataFeatures.PipelineStepObserver, UtilsFeatures.FileWriter): - def on_look(self, timestamp, frame): + def on_look(self, timestamp, ar_frame): """Log scan path metrics""" - if frame.analysis_available: + if ar_frame.analysis_available: log = ( timestamp, - frame.scan_path_analyzers['argaze.GazeAnalysis.Basic'].path_duration, - frame.scan_path_analyzers['argaze.GazeAnalysis.Basic'].steps_number + ar_frame.scan_path_analyzers['argaze.GazeAnalysis.Basic'].path_duration, + ar_frame.scan_path_analyzers['argaze.GazeAnalysis.Basic'].steps_number ) # Write to file @@ -75,14 +75,14 @@ from argaze.utils import UtilsFeatures class AOIScanPathAnalysisLogger(DataFeatures.PipelineStepObserver, UtilsFeatures.FileWriter): - def on_look(self, timestamp, layer): + def on_look(self, timestamp, ar_layer): """Log aoi scan path metrics""" - if layer.analysis_available: + if ar_layer.analysis_available: log = ( timestamp, - layer.aoi_scan_path_analyzers['argaze.GazeAnalysis.NGram'].ngrams_count + ar_layer.aoi_scan_path_analyzers['argaze.GazeAnalysis.NGram'].ngrams_count ) # Write to file @@ -101,3 +101,7 @@ Assuming that [ArGaze.GazeAnalysis.NGram](../../argaze.md/#argaze.GazeAnalysis.N |5687 |"{3: {}, 4: {}, 5: {}}"| |6208 |"{3: {('LeftPanel', 'GeoSector', 'CircularWidget'): 1}, 4: {}, 5: {}}"| |... |... | + +!!! note "" + + Learn to [script the pipeline](./advanced_topics/scripting.md) to know more about [ArFrame](../../argaze.md/#argaze.ArFeatures.ArFrame) and [ArLayers](../../argaze.md/#argaze.ArFeatures.ArLayer) attributes. \ No newline at end of file -- cgit v1.1