blewban_dataset

Tools written in python to give a user friendly access to the dataset collected at Iowa state university for BLE devices with health care application

https://github.com/mkashani-phd/blewban_dataset

Science Score: 57.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 6 DOI reference(s) in README
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (12.1%) to scientific vocabulary

Keywords

ble blewban physical-layer-security wban wireless-security
Last synced: 6 months ago · JSON representation ·

Repository

Tools written in python to give a user friendly access to the dataset collected at Iowa state university for BLE devices with health care application

Basic Info
  • Host: GitHub
  • Owner: mkashani-phd
  • License: mit
  • Language: Jupyter Notebook
  • Default Branch: main
  • Homepage:
  • Size: 182 MB
Statistics
  • Stars: 2
  • Watchers: 1
  • Forks: 2
  • Open Issues: 0
  • Releases: 1
Topics
ble blewban physical-layer-security wban wireless-security
Created almost 3 years ago · Last pushed over 1 year ago
Metadata Files
Readme License Citation

README.md

BLEWBAN_Dataset

BLEWBAN is a raw RF dataset of Bluetooth Low Energy (BLE) signals focused on Wireless Body Area Netwrok (WBAN). It consists of on-body and off-body recordings usign ESP32s in BLE mode. The advantages of this dataset is: - It covers the entire bandwith of the BLE technology.(recorded at 2.44GHz at 100MSps) - Recording in anechoic chamber to reduce unwanted signals or interference. - On-body recording on 12 different locations including: both left and right head, arm, wrist, chest, front and back torso (waist).
- Off-body recording with the same devices at 7-different orientations

Google colab examples

IEEE WCNC presentation YouTube Overview

IMAGE IEEE WCNC 2024 presentation

How to access dataset

Raw recording files

the raw files are available on IEEE Dataport with the DOI : https://dx.doi.org/10.21227/mtg7-eb43. In the RAWFileProcessing folder the tutorial.ipynb notebook provides a user friendly introduction of how to manage handle the raw files.

MongoDB database

However, the Python tools in this repository provide a user-friendly access to the dataset stored in a MongoDB database. A MongoDB database that can easily run queries in multiple languages even on online platforms such as Google Colab (example here). Supported languages can be found here.

An example of how to perform a query and store the results in a Pandas data frame on a Google Colab is available !

Installing requierments

pip3 install pymongo pip3 install pandas pip3 install numpy After succesfull installation import dependencies. python import pymongo import numpy as np import pandas as pd

Making connection to MongoDB database

There are two databases available. - BLE - BLE_metadata

BLEmetadata is the light version of the BLE excluding raw data. It contains basic time and frequency charectristics of the raw data and is much faster. On the other hand, The BLE database include raw recordings along with BLEmetadata.

For BLE use the following connection string python client = pymongo.MongoClient("mongodb://test:12345678910111213@SG-pine-beat-9444-57323.servers.mongodirector.com:27017/BLE") BLE_WBAN = client["BLE"]

Or for BLE_metadata use the following connection string python client = pymongo.MongoClient("mongodb://test:12345678910111213@SG-pine-beat-9444-57323.servers.mongodirector.com:27017/BLE_metadata") BLE_WBAN = client["BLE_metadata"]

Quering data

For example we are trying to filter off-body data recorded at atantenna 2 from device 1 in position 6 with 9dbm TX power.
python filter = {'antenna': '2', 'dvc':'1', 'pos': '6', 'txPower': '9dbm'} query = list(BLE_WBAN.offBody.find(filter)) df = pd.DataFrame(query) the above store a dataframe with columns such as: | | id | frameoriginfile | framenr | date | dvc | pos | SDR | test | txPower | antenna | ... | Fc | gain | frameTime | lenFrame | frameChnl | frameDecode | bitLen | maxgradientunwrapped_phase | I | Q | |:-:|:------------------------:|:-----------------:|:--------:|:-----------:|:---:|:---:|:---:|:-------:|:-------:|:-------:|:---:|:----------:|:----:|:----------------------:|:--------:|:---------:|:-----------------------:|:------------------:|:--------------------------------:|:------------------------------:|:------------------------------:| | 0 | 641aa1d333089480e2d0a5ca | /home/moh/... | 1 | jan 13 2023 | 1 | 6 | 1 | offBody | 9dbm | 2 | ... | 2439810000 | 31.5 | [1478146.0, 1487348.0] | 9202.0 | 3 | 0x5553d3d3c468a54267b1 | [185, 92, 101, ... | [-0.014498871, 0.0127564659, ... | [-0.01559495, -0.0057069, ... | [-0.00430310, 0.014526810, ... | | 1 | 641aa1d333089480e2d0a5cb | /home/moh/... | 3 | jan 13 2023 | 1 | 6 | 1 | offBody | 9dbm | 2 | ... | 2439810000 | 31.5 | [2978115.0, 2987351.0] | 9236.0 | 12 | 0x5553d3d3c4b4f71616de0 | [261, 96, 105, ... | [-0.013399868, 0.0109354282, ... | [0.00198370, -0.0071718, ... | [-0.01312295, -0.01129184, ... | | 2 | 641aa1d333089480e2d0a5cc | /home/moh/... | 8 | jan 13 2023 | 1 | 6 | 1 | offBody | 9dbm | 2 | ... | 2439810000 | 31.5 | [4478106.0, 4487332.0] | 9226.0 | 21 | 0x5553d3d3c40ce5d128c1 | [256, 96, 105, ... | [-0.013268690, 0.0109537563, ... | [-0.00790429, -0.00302133, ... | [-0.00939970, -0.01232947, ... | | 3 | 641aa1d333089480e2d0a5cd | /home/moh/... | 10 | jan 13 2023 | 1 | 6 | 1 | offBody | 9dbm | 2 | ... | 2439810000 | 31.5 | [5978104.0, 5987324.0] | 9220.0 | 30 | 0x5553d3d3c4f4645966200 | [251, 96, 104, ... | [-0.014260522, 0.0117406014, ... | [-0.00427259, -0.01013215, ... | [0.01345866, -0.005706963, ... |

Data interpretaion

Since storing Complex numbers is not possible in the MongoDB database columns I and Q are real and imaginary numbers respectively. The code below will generate a new column named frame that is $I + j*Q$ python df['frame'] = query.apply(lambda x: x['I'] + np.dot(x['Q'],1j), axis=1)

Examples of the BLE-WBAN

There is ongoing research on analyzing the on-body data. The plot below shows the classification results of 12 on-Body devices in moving and static body positions.

img

Owner

  • Name: Moh Kashani
  • Login: mkashani-phd
  • Kind: user
  • Location: Ames, Iowa

PhD student in computer engineering. Focusing on security in wireless networks. interested in new technologies such as quantum computers.

Citation (CITATION.cff)

cff-version: 1.2.0
message: "If you use this software, please cite it as below."
authors:
- family-names: "Kashani"
  given-names: "SeyedMohammad"
  orcid: "https://orcid.org/0009-0005-9232-0451"
- family-names: "Sherazi"
  given-names: "Syed"
- family-names: "Khokhar"
  given-names: "Ashfaq"
- family-names: "Kim"
  given-names: "Sang"
- family-names: "Nait-Abdesselam"
  given-names: "Farid"
  
title: "BLE-WBAN Dataset Tools"
version: 0.0.1
doi: 10.21227/mtg7-eb43
date-released: 09-22-2023
url: "https://github.com/mkashani-phd/BLEWBAN_Dataset"

GitHub Events

Total
  • Watch event: 4
Last Year
  • Watch event: 4

Dependencies

.github/workflows/python-publish.yml actions
  • actions/checkout v3 composite
  • actions/setup-python v3 composite
  • pypa/gh-action-pypi-publish 27b31702a0e7fc50959f5ad993c78deac1bdfc29 composite
Examples/requirements.txt pypi
  • keras *
  • matplotlib *
  • numpy *
  • pandas *
  • pymongo *
  • scikit-learn *
  • scipy *