Giter VIP home page Giter VIP logo

specgram's People

Contributors

bojidar-bg avatar rimio avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

specgram's Issues

README typos

First sentence under Display Options reads You will notice that there isn't much difference between the output of the above command and the others which makes no sense, as the rx_sdr example has been added.

then you can use the -q -> then you can use -q

Fix these.

Unit testing

Unit testing for testable things like ColorMap, FFT, InputParser, InputReader, parts of Renderer, ValueMap, WindowFunction.

  • ColorMap
  • FFT
  • InputParser
  • InputReader
  • Renderer
  • ValueMap
  • WindowFunction

Really cool default colormap.

The jet colormap is a classic, but I have to admit it looks like crap for live (scrolling) spectrograms.

A cool but easy on the eyes colormap is required.

Allow custom scale string

Allow definition of custom scale strings using the -s, --scale options.

dBFS will remain a special case and default option, as it uses the dBFSValueMap which clamps the values to an upper limit of 0.

Add new LinearValueMap and dBValueMap value maps which map the values accordingly.

If the string begins with db or dB then it defaults to dBValueMap and the rest of the string is used for display purposes. Limits can be specified with, maybe, commas? I.e. -s dBm,20,-20 specifies the limits for a dBValueMap.

Otherwise it uses a LinearValueMap with the limits specified as above.

Stop on EOF from stdin

As per one user's request:

(also, I wonder if it would make sense for specgram to stop whenever the stream ends; I'm guessing around AsyncInputReader::ReachedEOF(). Since, once we get an EOF on stdin, there should be no way to get more data in... right?)

Process is busywaiting when no input is present

While good for latency during high throughput scenarios, it's not necessarily nice to keep a CPU at 100% while waiting for input.

Explore the ideas of:

  • introducing std::this_thread::sleep_for in the two cases where we wait for input within the main loop
  • introducing a flag for activating the above behavior (i.e. busywait by default, wait on flag set)

Allow stdout output with `-`

Allow dumping of PNG image data to stdout, where the user can display it with imagemagick. E.g.:

specgram -i infile - | display

Refactoring #1

  • LiveOutput caches the Configuration object, but also caches ColorMap and ValueMap. Maybe split relevant stuff from Configuration?
    Renderer caches Configuration, maybe shouldnt?
  • Renderer::*fft_area* stuff refer to the spectrogram fields, so should be named accordingly.
  • const auto MustDumpToStdout() const -> auto MustDumpToStdout() const

Legend ticks are badly spaced

Command line:

./specgram -eq -f 8192 -y 4000 --bg-color=00000000 --fg-color=000000ff -i ../resources/clips/rammstein_dalai_lama example_file.png

Output:
example_file

Drop spdlog as a dependency

The program's logging needs are rather simplistic, so there's no need to keep spdlog as a dependency, especially after the incompatibility issues with fmt 8.0.0.

Write own logging routine.

Build failure

Build fails under ArchLinux, cannot find std::clamp().

Assertion failed on small frequency band

$ ./specgram -lq -x 1 -y 100
[INFO] Creating 1024-wide FFTW plan
[INFO] Scale decibel, unit FS, bounds [-120, 0]
specgram: /home/rimio/git/specgram/src/renderer.cpp:396: std::__cxx11::list<std::tuple<double, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > Renderer::GetNiceTicks(double, double, const string&, unsigned int, unsigned int, bool): Assertion `fval <= v_max' failed.
Aborted (core dumped)

Functional testing

Write functional tests that make sure the overall output to known inputs is correct.

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.