Package: bannotator
Behavior AnnotatorTable of contentsInstallationUsageGUIVideoAnnotationKeyPress FunctionsContributingAcknowledgementLicenseInstallationInstall GitIn git bash, rungitclonehttps://github.com/hsingchien/Bannotator.gitIn anaconda prompt, go to annotator directory, runcondaenvcreate-fenvironment.ymlThen activate the environmentcondaactivatebannotatorUnder this environment, go to the bannotator directory, runpythonsetup.pydevelopTo open the app, under this environment, runannotate-behaviorUsageGUIThe GUI layout has 5 major areas.Video display area, where you can add multiple videos.Stream area shows the enlarged portion of the color coded streams.Stream overviews provide the bird's-eye view of the full annotation and the current progress.Behavior table dock where ID, name, keystroke and color are shown in the Behaviors tab; number of epochs and percentage of the time are shown in the Stats tab.Epoch tables where epochs are shown in the All Epochs tab, epochs of selected behaviors are shown in the Behavior Epochs tab.VideoAnnotator supports major video formats and the Norpix Streampix seq files. Only uncompressed seq (RAW) or compressed seq in JPEG format are currently supported.Annotator is capable of displaying multiple videos simultaneously, therefore is great for experiments with multiple video streams. If videos have different number of frames, the 1st added video is treated as the main video and the other videos are stretched to the length of the video 1.Annotator provides several different video layouts. Side by side, Stacked or Grid (this option becomes available when number of videos reaches 4).Video can be played at various speed.AnnotationThe annotator is compatible with the format of annotation txt file ofPiotr's MATLAB toolbox. If you are a user of the behavior annotator of this toolbox, you can view/edit your existing annotation files as well as keep using your configuration files to create new annotations. The output annotation txt files are also back compatible with Piotr's annotator.If you do not have configuration files to start with, you can create an new annotation from scratch usingNew annotaiondialog in theAnnotationmenu. To enable this option you need to add a video first so that the annotator knows the length of the annotation.First, set the number of streams. In the text editor, input behavior - keystroke pair in each line, parsed by '-' or space. The dialog actively checks the input to ensure the behavior-keystroke pairs are unique. Once created, all the streams will be initialized with the first behavior in your list. Usually the first behavior label is reserved for the blank label of name "other" or "blank", which will be assigned grey color.Once the new streams are created, go through the video and label the events. Press keystroke to label the current frame as well as the rest of the Epoch.Epochis the fundamental unit of the annotation. AnAnnotationcontainsStreamswhich contains a series ofEpoch. EachStreamalso contains severalBehaviorobjects each one of which stores name, color, keystroke and ID of a user defined behavior.Behaviorobjects also collects all theEpochsof this kind in its stream.KeyPress FunctionsSpace: Play/Pause video↑/↓: Increase/Decrease playing speed←/→: Previous/Next frame1-0: Change the current stream to stream 1 - 10`: Rotate current stream through all streams-/+: Move to previous/next epoch of current streamCTRL-/CTRL+: Move to previous/next epoch of selected behaviorContributingYour contributions are always welcome! Contribution guideline will be available soon.AcknowledgementThis project is inspired byPiotr's MATLAB toolbox.Seq file reading is inspired byPIMS.Random color generatordistinctipyThe project is built withPySide6.LicenseThe MIT License (MIT) 2017 -Xingjian Zhang.