Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Signal #6

Merged
merged 10 commits into from
Jun 12, 2024
57 changes: 39 additions & 18 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,31 +15,44 @@ on:

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
branch: [version-1-6, devel]
target: [linux, macos, windows]
include:
- target: linux
builder: ubuntu-latest
- target: macos
builder: macos-latest
- target: windows
builder: windows-latest
name: '${{ matrix.target }} (${{ matrix.branch }})'
runs-on: ${{ matrix.builder }}
nim:
- '1.6.x'
- '2.0.x'
- 'stable'
os:
- ubuntu-latest
- windows-latest
- macOS-latest
name: '${{ matrix.nim }} (${{ matrix.os }})'
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
path: impulse

- name: Setup Nim
uses: alaviss/setup-nim@0.1.1
- name: Setup nim
uses: jiro4989/setup-nim-action@v1
with:
path: nim
version: ${{ matrix.branch }}
nim-version: ${{ matrix.nim }}
repo-token: ${{ secrets.GITHUB_TOKEN }}

- name: Setup MSYS2 (Windows)
if: ${{matrix.target == 'windows'}}
uses: msys2/setup-msys2@v2
with:
path-type: inherit
update: true
install: base-devel git mingw-w64-x86_64-toolchain

- name: Install dependencies (Windows)
if: ${{matrix.target == 'windows'}}
shell: msys2 {0}
run: |
pacman -Syu --noconfirm
pacman -S --needed --noconfirm mingw-w64-x86_64-lapack

- name: Setup nimble & deps
shell: bash
Expand All @@ -48,12 +61,20 @@ jobs:
nimble refresh -y
nimble install -y

- name: Run tests
- name: Run tests (Linux & OSX)
if: ${{matrix.target != 'windows'}}
shell: bash
run: |
cd impulse
nimble -y test

- name: Run tests (Windows)
if: ${{matrix.target == 'windows'}}
shell: msys2 {0}
run: |
cd impulse
nimble -y test

- name: Build docs
if: >
github.event_name == 'push' && github.ref == 'refs/heads/master' &&
Expand Down
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Impulse will be a collection of signal processing primitives for Nim.

## FFT

Currently this library only consists of an FFT module, which wraps
The FFT part of this library wraps
[PocketFFT](https://gitlab.mpcdf.mpg.de/mtr/pocketfft).

For the C++ backend an optimized version of PocketFFT is used, in the
Expand Down Expand Up @@ -189,6 +189,10 @@ As a convenience, a `tap_examples` function is provided. This function takes a
The LFSR module implementation is favors simplicity over speed. As of 2024, it
is able to generate 2^24 values in less than 1 minute on a mid-range laptop.

## Signal

The Signal module implements several signal processing and related functions, such as a Kaiser window and a firls FIR filter design function. See the documentation of those functions for more details.

## License

Licensed and distributed under either of
Expand Down
5 changes: 3 additions & 2 deletions impulse.nimble
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,16 @@

version = "0.1.1"
author = "SciNim"
description = "Signal processing primitives (FFT, ...)"
description = "Signal processing primitives (FFT, filtering, ...)"
license = "MIT"


# Dependencies

requires "nim >= 1.6.0"
requires "arraymancer >= 0.7.28"
requires "arraymancer >= 0.7.30"

task test, "Run standard tests":
exec "nim c -r tests/test_fft.nim"
exec "nim c -r tests/test_fft2.nim"
exec "nim c -r tests/test_signal.nim"
Loading
Loading