Re: [Discuss-gnuradio] New to GnuRadio (Fortran own blocks?)

2011-11-26 Thread Moritz Fischer

On 11/26/2011 09:18 AM, Uzair Baig wrote:

 Here is what I am planning. I am thinking of writing my own Fortran 
blocks

 (we are a team of 4 so yes that is possible) and integrating that with
 python; NumPy and then use that to connect with other basic blocks.

Another way to use Fortran in GNU Radio is to wrap them in a C++ block, 
you might want to have a look at [0] to see how we did that. This 
however supposes that you actually want to use the GNU Radio runtime to 
write a GNU Radio application (which I'm not entirely sure of is what 
you want to do). Maybe you could elaborate further on what you are 
actually planning to do?


 Please tell me if that will work (as in how much efficient would that 
be), and

 whether there is a way round understanding the blocks.

If I understand you correctly you want to have an answer on how 
efficient that is and if it is possible to do this *without* 
understanding the blocks?!


 We are okay in making our own Fortran blocks and working, but we need 
to be

 sure. And would really like if we can find some book/manual to understand
 on what convention was the blocks already existing made, etc, so we use
 most of the existing work done.

I think there is no official convention for writing Fortran blocks in 
GNU Radio, but for coding guidelines see README.hacking.


May I ask a final question, why did you select Fortran? Do you have a 
lot of matrix computations to do?


In our case we used Fortran for several reasons including wanting to 
learn how to do it, and (to our knowledge) the lack of equally fast 
implementations in C/C++ of the matrix computations involved.


Cheers  happy hacking,

Moritz

[0] http://github.com/kit-cel/gr-specest.git

___
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio


Re: [Discuss-gnuradio] New to GnuRadio (Fortran own blocks?)

2011-11-26 Thread Uzair Baig
Thank you Mortiz for your reply.

We are trying to basically do all the processing of the data in a program,
without passing it through blocks, like a basic code. We are using Fortran
for two reasons, as its faster than C++ in certain aspects, and secondly,
integrating the code (simple code, doesn't make use of classes etc) with
NumPy seems easier.I would like to know if I take the data from USRP, write
it to a file. Get the data from the file, start processing it via Fortran
integrated in NumPy, and again using USRP transmit again, will that be
efficient enough?

Why exactly are we wanting to do all of this, instead of just using the
blocks - I mention again, because we don't understand how the C++ blocks of
GnuRadio work, function.

Uzair Baig


On Sat, Nov 26, 2011 at 6:22 PM, Moritz Fischer
gnura...@pure-entropy.orgwrote:

 On 11/26/2011 09:18 AM, Uzair Baig wrote:

  Here is what I am planning. I am thinking of writing my own Fortran
 blocks
  (we are a team of 4 so yes that is possible) and integrating that with
  python; NumPy and then use that to connect with other basic blocks.

 Another way to use Fortran in GNU Radio is to wrap them in a C++ block,
 you might want to have a look at [0] to see how we did that. This however
 supposes that you actually want to use the GNU Radio runtime to write a GNU
 Radio application (which I'm not entirely sure of is what you want to do).
 Maybe you could elaborate further on what you are actually planning to do?


  Please tell me if that will work (as in how much efficient would that
 be), and
  whether there is a way round understanding the blocks.

 If I understand you correctly you want to have an answer on how efficient
 that is and if it is possible to do this *without* understanding the
 blocks?!


  We are okay in making our own Fortran blocks and working, but we need to
 be
  sure. And would really like if we can find some book/manual to understand
  on what convention was the blocks already existing made, etc, so we use
  most of the existing work done.

 I think there is no official convention for writing Fortran blocks in GNU
 Radio, but for coding guidelines see README.hacking.

 May I ask a final question, why did you select Fortran? Do you have a lot
 of matrix computations to do?

 In our case we used Fortran for several reasons including wanting to learn
 how to do it, and (to our knowledge) the lack of equally fast
 implementations in C/C++ of the matrix computations involved.

 Cheers  happy hacking,

 Moritz

 [0] 
 http://github.com/kit-cel/gr-**specest.githttp://github.com/kit-cel/gr-specest.git

 __**_
 Discuss-gnuradio mailing list
 Discuss-gnuradio@gnu.org
 https://lists.gnu.org/mailman/**listinfo/discuss-gnuradiohttps://lists.gnu.org/mailman/listinfo/discuss-gnuradio

___
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio


Re: [Discuss-gnuradio] New to GnuRadio (Fortran own blocks?)

2011-11-26 Thread Josh Blum

 We are trying to basically do all the processing of the data in a program,
 without passing it through blocks, like a basic code. We are using Fortran
 for two reasons, as its faster than C++ in certain aspects, and secondly,
 integrating the code (simple code, doesn't make use of classes etc) with
 NumPy seems easier.I would like to know if I take the data from USRP, write


To use the gnuradio framework, you have 2 options:
write the blocks in python or write the blocks in c++

Writing blocks in python is a recent invention of mine that hasnt made
it into the mainline code:
http://gnuradio.org/redmine/projects/gnuradio/wiki/WriteBlocksInPython

Now, the actual implementation of your work() function, the code that is
doing all the heavy lifting can be written however, anyway, anyhow you like.

My only advice is to get everything working first in whatever language
you are most comfortable or efficient with. If thats fortran, than so be
it, but dont use fortran because of some programming misnomer.

When you want performance, then optimize your code with SIMD. Blocks
calling into volk kernels are a great example.

-josh

___
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio