{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "#### Introduction to the JABS downstream analysis" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "1. Importing necessary libraries\n", "\n", "\n", "###### We are just going to import basic python libraries to help us analyze predicted behavior" ] }, { "cell_type": "code", "execution_count": 7, "metadata": {}, "outputs": [], "source": [ "# auto reload\n", "%load_ext autoreload\n", "%autoreload 2" ] }, { "cell_type": "code", "execution_count": 8, "metadata": {}, "outputs": [], "source": [ "from stuff import *\n", "from ipywidgets import FloatSlider, interactive, fixed" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "2. Visualizing the Ethogram for a sample prediction\n" ] }, { "cell_type": "code", "execution_count": 14, "metadata": {}, "outputs": [ { "data": { "application/vnd.jupyter.widget-view+json": { "model_id": "20328a1857e5430c9bd1027fcfa7dc7e", "version_major": 2, "version_minor": 0 }, "text/plain": [ "interactive(children=(FloatSlider(value=1.0, description='i', min=1.0, step=1.0), Checkbox(value=False, descri…" ] }, "metadata": {}, "output_type": "display_data" } ], "source": [ "# Reading the sample file\n", "df = load_file('data/sample_file.h5')\n", "int_plot = interactive(draw_ethogram, df=fixed(df['Class'].values.astype(int)),i=FloatSlider(min=1, max=100, step=1), save_fig=False);\n", "int_plot\n" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "2. Frame counting statistics" ] } ], "metadata": { "kernelspec": { "display_name": "Python 3.9.7 ('base')", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.9.7" }, "orig_nbformat": 4, "vscode": { "interpreter": { "hash": "1a67a0a5dc90b6baff31c17643e982bdc57f5c09f0462559483471e4cb8ef887" } } }, "nbformat": 4, "nbformat_minor": 2 }