Re: [Discuss-gnuradio] Import issue
On Fri, Jun 06, 2008 at 08:35:41AM -0700, irene159 wrote: > > > In my case, it works replacing "from gnuradio import blks2" by "from > gnuradio.blks2impl import rational_resampler" but that doesn't explain why > command line works from the terminal but not from the file... > > irene159 wrote: > > > > Hello, > > > > Concerning blks2 import (blks2.rational_resampler needed) > > > > "from gnuradio import blks2" works on python command line but not in > > python file (ImportError: cannot import name blks2). > > > > Where can this come from? > > > > Regards, > > Irene What directory are you in when you're trying to run your example? Does that directory have a gnuradio subdirectory? Try running it in a different directory. You may want to spend some time with the python docs to understand how imports are resolved. Eric ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] Import issue
In my case, it works replacing "from gnuradio import blks2" by "from gnuradio.blks2impl import rational_resampler" but that doesn't explain why command line works from the terminal but not from the file... irene159 wrote: > > Hello, > > Concerning blks2 import (blks2.rational_resampler needed) > > "from gnuradio import blks2" works on python command line but not in > python file (ImportError: cannot import name blks2). > > Where can this come from? > > Regards, > Irene > > -- View this message in context: http://www.nabble.com/Import-issue-tp17688627p17695168.html Sent from the GnuRadio mailing list archive at Nabble.com. ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
[Discuss-gnuradio] Import issue
Hello, Concerning blks2 import (blks2.rational_resampler needed) "from gnuradio import blks2" works on python command line but not in python file (ImportError: cannot import name blks2). Where can this come from? Regards, Irene -- View this message in context: http://www.nabble.com/Import-issue-tp17688627p17688627.html Sent from the GnuRadio mailing list archive at Nabble.com. ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org http://lists.gnu.org/mailman/listinfo/discuss-gnuradio