Coder Social home page Coder Social logo

zeigar / hhsa_cpu_openmp Goto Github PK

View Code? Open in Web Editor NEW

This project forked from cardlin/hhsa_cpu_openmp

0.0 0.0 0.0 4.69 MB

Holo-Hilbert Spectral Analysis (HHSA) OpenMP version: Huang, Norden E., et al. "On Holo-Hilbert spectral analysis: a full informational spectral representation for nonlinear and non-stationary data." Philosophical Transactions of the Royal Society A: Mathematical, Physical and Engineering Sciences 374.2065 (2016): 20150206.

C++ 99.73% Makefile 0.20% Batchfile 0.07%

hhsa_cpu_openmp's Introduction

Holo-Hilbert Spectral Analysis (HHSA)

OpenMP Version

Introduction

  • This program contain Hilbert–Huang Transform (HHT) and Holo-Hilbert Spectral Analysis (HHSA)

  • We will doing HHT with Complete Ensemble Empirical Mode Decomposition (CEEMD) or Ensemble Empirical Mode Decomposition (EEMD) to get several Intrinsic Mode Function (IMF)

  • And then use the result of IMF to do HHSA (Calculate (CEEMD or EEMD) with Upper Envelope (UpEnvelope in Code) of IMF as Input since we are focus on the ECG peak, you can change it to LowEnvelope by modify the code)

  • The parallel computing by OpenMP is doing on EEMD. We recommended that Ensemble Number in HHSA_profile.txt should equal to the multiples of CPU Threads Count.

  • In this code, we use "normal_distribution" random number generator to generate the Noise that add per EEMD iteration. You can change it to "uniform_real_distribution" by modify the code.

  • Original HHSA Paper here: https://royalsocietypublishing.org/doi/10.1098/rsta.2015.0206

  • And Instantaneous Frequency Paper here: https://www.worldscientific.com/doi/10.1142/S1793536909000096

Hardware Requirement

  • At leaset 2.4GB Free Memory to run our small sample. (HeartRate.txt)

Compiling

  • Unzip Library: mathgl-8.0-MSVC to C:\mathgl-8.0-MSVC

  • open HHSA_CPU_OpenMP.sln with Visual Studio 2022 and Choose Release x64 then Build

Execution

  • Move files in Profile Folder to x64\Release Folder

  • copy dll from C:\mathgl-8.0-MSVC\bin to x64\Release

  • modify parameter in HHSA_profile.txt, modify input file in Run_HHSA.bat

  • Execute Run_HHSA.bat

Explanation

  • (INPUT)_HHT.csv contain the result of HHT

    • IMF: Intrinsic Mode Function

    • Residual: The residual value after each mode decomposition

    • Up: UpperEnvelope

    • Low: LowerEnvelope

    • Mean: MeanEnvelope

    • FM: Frequency Modulation

    • AM: Amplitude Modulation

    • IP: Instantaneous Phase

    • IF: Instantaneous Frequency

  • (INPUT)_HSA.png is the Hilbert Spectra Analysis that plot the Instantaneous Frequency across time

  • (INPUT)_HHSA_mode(NUM).csv contain the result of HHSA on each mode of the HHT on IMF Upper Envelope

  • (INPUT)_HHS.png is the Holo-Hilbert Spectra that plot the AM Frequency and FM Frequency by HHSA result (Sum of all time)

  • (INPUT)_HHSA_3D.png is the Holo-Hilbert Spectra Analysis result which is a short time HHS according to TimeCell Duration along Time

Linux

  • Debian/Ubuntu: "apt-get install libmgl-dev g++ make"

  • CentOS: "yum install mathgl-devel gcc-c++ make" (I don't really test it, jsut copy paste)

  • cd to HHSA_CPU_OpenMP folder which contain Makefile: "make"

  • "./HHSA_CPU_OpenMP HeartRate.txt"

Notice

  • This code is done in my spare time. Not verified by third party.

hhsa_cpu_openmp's People

Contributors

cardlin avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.