{ "cells": [ { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [], "source": [ "%load_ext autoreload\n", "%autoreload 2" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ "14:03:52 [I] klustakwik KlustaKwik2 version 0.2.6\n" ] } ], "source": [ "import os\n", "import expipe\n", "import pathlib\n", "import numpy as np\n", "import spatial_maps.stats as stats\n", "import septum_mec.analysis.data_processing as dp\n", "import head_direction.head as head\n", "import spatial_maps as sp\n", "import septum_mec.analysis.registration\n", "import speed_cells.speed as spd\n", "import septum_mec.analysis.spikes as spikes\n", "import re\n", "import joblib\n", "import multiprocessing\n", "import shutil\n", "import psutil\n", "import pandas as pd\n", "import matplotlib.pyplot as plt\n", "import septum_mec\n", "import scipy.ndimage.measurements\n", "from distutils.dir_util import copy_tree\n", "\n", "from tqdm import tqdm_notebook as tqdm\n", "from tqdm._tqdm_notebook import tqdm_notebook\n", "tqdm_notebook.pandas()" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, "outputs": [], "source": [ "max_speed = 1, # m/s only used for speed score\n", "min_speed = 0.02, # m/s only used for speed score\n", "position_sampling_rate = 100 # for interpolation\n", "position_low_pass_frequency = 6 # for low pass filtering of position\n", "\n", "box_size = [1.0, 1.0]\n", "bin_size = 0.02\n", "smoothing_low = 0.03\n", "smoothing_high = 0.06" ] }, { "cell_type": "code", "execution_count": 4, "metadata": {}, "outputs": [], "source": [ "project_path = dp.project_path()\n", "\n", "project = expipe.get_project(project_path)\n", "actions = project.actions" ] }, { "cell_type": "code", "execution_count": 5, "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", " | action | \n", "channel_group | \n", "unit_name | \n", "
---|---|---|---|
0 | \n", "1849-060319-3 | \n", "1 | \n", "104 | \n", "
1 | \n", "1849-060319-3 | \n", "1 | \n", "108 | \n", "
2 | \n", "1849-060319-3 | \n", "1 | \n", "85 | \n", "
3 | \n", "1849-060319-3 | \n", "1 | \n", "94 | \n", "
4 | \n", "1849-060319-3 | \n", "1 | \n", "98 | \n", "