Capturing Sensor Data

Next, we are going to go over how to collect sensor data from your device within the Data Capture Lab. If you have your own tools for doing data collection, the DCL can import external sensor data files from any source. See more on importing data in the Importing External Sensor Data user guide.

If you are using the Slide Demo dataset, it already comes with 13 pre-collected sensor data files. This means you can skip data collection if you do not have a device at this time.

Follow the steps below to setup your device for data collection.

  1. Open your project in the Data Capture Lab

  2. Click Switch Modes

../../_images/dcl-switch-modes-label.png
  1. Open Capture mode

../../_images/dcl-mode-capture.png

Configuring Your Device

It is important you collect your sensor data with the same sensor settings that you plan to use for your event detection sensor. Collecting data with different settings can cause unexpected results depending on various aspects like sensor orientation and sensor calibration settings. It is also important that you configure the device with the same sample rate frequency you plan on using in your final product.

  1. Click Setup Sensor Configuration to setup a new sensor configuration

../../_images/dcl-setup-sensor-configuration.png
  1. Select a plugin for the device you wish to use during data collection. If you are using a device not listed in the supported devices you can see more on how to implement your own plugin for data collection in the Adding Custom Device Firmware Documentation

../../_images/dcl-select-a-plugin.png
  1. After selecting a plugin, the DCL will show more information about the plugin including the available sensors and documentation links. Each plugin will have different available options. Click Next to move to the sensor properties screen

../../_images/dcl-plugin-details.png
  1. Select the sensor properties you wish to use for data collection and click Next. If you are following the Getting Started Slide Demo Project set sample rate to about 100 hz and select the Accelerometer and Gyroscope sensors if they are available in your device plugin

../../_images/dcl-sensor-properties.png
  1. Enter a profile name for the sensor configuration and click Save

    ../../_images/dcl-save-sensor-configuration.png

Recording Sensor Data from Your Device

Before you can use your device for data collection make sure it is flashed with data collection firmware. You can find more information on data collection firmware options and flash instructions in the SensiML Firmware Documentation.

  1. After setting up your Sensor Configuration profile, click Find Devices to connect to your device. Your device capture method options may be different from the screenshot based on the device plugin you are using

../../_images/dcl-find-devices.png
  1. Select the labels and metadata you wish to use during data collection

../../_images/dcl-capture-labels-and-metadata.png
  1. Click Begin Recording and the DCL will start recording based on your selected collection method. If you are using a connection that streams the data (BLE, Serial, etc) then the DCL will automatically save the file to your local hard drive and upload it to the cloud

../../_images/dcl-begin-recording.png

At this point we will capture examples of all the events you are trying to detect in your project. The amount of data you need to collect will be different from project to project depending on the events of interest and amount of variation you are looking to build in your project. In the Slide Demo Project there is only three simple events to detect so we do not need a lot of data.

  1. Collect 4 files for each of the events in the Slide Demo events (Horizontal, Stationary, Vertical). Each file should last for 60 seconds. In the end you should end up with a total of 12 files in your project. Note that if you downloaded the Slide Demo dataset it already comes with pre-collected files so you do not need to collect any new data

As you collect your files, it’s good to keep in mind how much variation you want in your events of interest. You are essentially training your project with examples of what you want to detect, so you want to make sure to collect enough variation in your events of interest to build a robust model. For example in the Slide Demo, while collecting the Stationary events you may want to tap on the table near your sensor so that small vibrations are not misclassified as a Vertical event. For the Horizontal and Vertical events you may want to collect small and large gesture examples so that your project can detect more robust events of interest.