|From:||Kyeong Su Shin|
|Subject:||Re: Generation of data and file extensions|
|Date:||Sun, 28 Nov 2021 14:31:07 +0000|
Hello Aditya Arun Kumar,
First, GNU Radio Wiki have information regarding that. ( https://wiki.gnuradio.org/index.php?search=File+Sink&title=Special%3ASearch&fulltext=1 )
So, the traditional way to store data samples into a file is to... just write them directly into a file, in binary. No metadata, no header, no tags, just a stream of the data right from GNU Radio. If the input type is complex64 (32bit IEEE754 I + 32bit IEEE754 Q), it will be interleaved as I-Q-I-Q-I-Q. That's what a File Sink will do by default. It is easy to parse, but it doesn't keep necessary information (sampling rates, dates, etc) for you. See: https://wiki.gnuradio.org/index.php/File_Sink
An alternative way to store data is "File Meta Sink". It keeps some metadata for you, but it may require some additional efforts if you want to use this on non-GNU Radio environments. See: https://wiki.gnuradio.org/index.php/File_Meta_Sink
An another hacky way is to treat the I-Q samples as a stereo audio, and use wav format to store the them (yes, some people do this). I don't prefer this, but apparantly this works well for some HAM radio operators.
Finally, "the modern way" to store the stream into a file is to follow SigMF standard. It's actually quite straightforward. See: https://github.com/gnuradio/SigMF .
2.The extension does not change the behavior of the "File Sink" block (*.dat == *.bin == *.cf32 == *.cfile), assuming that "File Sink" is the block that you are using to store the data. cf32 or cfile are used to signify that the contained data are in complex number. That's all. Again, see: https://wiki.gnuradio.org/index.php/File_Sink for parsing the data.
Kyeong Su Shin
보낸 사람: Aditya Arun Kumar <email@example.com> 대신 Discuss-gnuradio <firstname.lastname@example.org>
보낸 날짜: 2021년 11월 28일 일요일 오후 10:57
받는 사람: GNURadio Discussion List <email@example.com>
제목: Generation of data and file extensions
So, I have been trying to get a hold of some of the DSP libraries used out there, for that, I felt like I need a data set with which I can test and train myself on these libraries. To this end, I wanted to use GRC to generate some signals samples. I have some questions regarding this font.
1. What are the possible file formats that I can save the data in, I understand this depends on what data type is being used in the flowgraph blocks, but getting a better understanding on this front would be helpful in understanding GRC and numbers from them a bit better.
2. Some tutorials online say and use a dataset with .dat file extension, how is this going to vary from .bin, .cf32, or .cfile which is better, and how each data point inside the data-set will look like? (A link or some reference would be good)
3. If anyone can provide me with some links that can help me in this effort like reference materials or some tutorials, will be really helpful (I am planning on starting with fftw, kfrlib and liquid-dsp)
S. Aditya Arun Kumar
|[Prev in Thread]||Current Thread||[Next in Thread]|