I can't reproduce the problem.
julia> versioninfo()
Julia Version 0.5.0
Commit 3c9d753 (2016-09-19 18:14 UTC)
Platform Info:
System: Linux (x86_64-pc-linux-gnu)
CPU: Intel(R) Core(TM) i5-3320M CPU @ 2.60GHz
WORD_SIZE: 64
BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Sandybridge)
This gets close to what you want, and works in a script (on Julia v0.4.6):
exitflag = [false]
@async while true
g = utf8(readavailable(STDIN))
println(g)
if g[1] == 'q'
println("Exiting task...")
exitflag[1] = true
break
end
end
while true
yield()
if exitflag[1]
break
end
end
This code prints
You can simplify the declaration as follows:
MM = Matrix(Matrix(1,2))
You can use comprehensions too:
MM = [ randn(5,5) for x=1:2, y=1 ]
Here, MM has two rows and one column, and each of its elements is a 5x5
matrix.
-- mb
On Thu, Jun 23, 2016 at 9:28 PM, Sheehan Olver
This may be related: https://github.com/JuliaLang/julia/issues/16248
On Sun, Jun 5, 2016 at 6:16 PM, Anonymous wrote:
> So I have a BysteString vector A, containing a bunch of byte strings of
> varying lengths of the form:
>
> "1,2,\n"
> "\n"
> "5,2,4\n"
>
> etc.
>
> What I
I think this is similar to the distinction between 'function' and
'procedure' in languages like Pascal. Maybe we could leave functions as
they are (which I'd prefer), and add procedures that are like functions but
with an implicit 'return nothing' at the end.
-- mb
On Wed, May 25, 2016 at 6:40
You seem to be missing graphviz: http://www.graphviz.org/
-- mb
On Thu, May 19, 2016 at 12:21 PM, Andrea Vigliotti <
andrea.viglio...@gmail.com> wrote:
> Hi all!
>
> I'm trying to run this example (taken from here :
> https://github.com/JuliaLang/Graphs.jl/blob/master/doc/source/examples.rst
>
The easiest way to write slow for loops is to make them row-major instead
of column-major.
-- mb
On Thu, May 12, 2016 at 8:46 AM, Anonymous wrote:
> So I guess the consensus is not that Julia's devectorized code is so much
> faster than its vectorized code (in fact I keep
> a line segment from the low_range to the high_range (with the top and
bottom marked off with small horizontal lines),
Gaston has support for plotting with error bars, which is exactly this type
of plot. Current documentation is here:
That I don't know, sorry.
-- mb
On Sat, Mar 26, 2016 at 6:44 PM, feza <mohamad...@gmail.com> wrote:
> Sorry I meant without using ;
>
> I.e. to have it permanently without ;
>
> On Saturday, March 26, 2016 at 6:40:16 PM UTC-4, Miguel Bazdresch wrote:
>>
>> 3;
3;
On the REPL the ; acts just like it does in Matlab, suppressing the output.
-- mb
On Sat, Mar 26, 2016 at 6:34 PM, feza wrote:
> julia> 3
> 3
>
>
> How can I suppress this during an interactive julia session
>
> Thanks
>
at 9:55 PM, Yichao Yu <yyc1...@gmail.com> wrote:
> On Sun, Mar 13, 2016 at 9:47 PM, Miguel Bazdresch <eorli...@gmail.com>
> wrote:
> > While trying to optimize some code for performance, I noticed that rand()
> > and randn() generate much more code than rand(1) and randn
While trying to optimize some code for performance, I noticed that rand()
and randn() generate much more code than rand(1) and randn(1). In addition,
rand() and randn() have type instabilities, easily seen with @code_warntype.
It seems to me than rand() should be faster and generate less code
I think it'd be great to use this PRNG in julia: http://www.pcg-random.org/
-- mb
On Tue, Mar 1, 2016 at 6:28 AM, Upekshe Jayasekera <
upekshej...@cse.mrt.ac.lk> wrote:
> Hi All,
> I am an final year CSE undergraduate in University of Moratuwa. I am new
> to julia. But I have heard about julia
Gaston has support for 3D plots and can save them to GIF files. Take a look
at the documentation here:
https://bitbucket.org/mbaz/gaston/downloads/gastondoc-0.5.5.pdf
I recommend using Gaston "master" instead of the latest release; it has a
lot of bugfixes and improvements. The docs for 3-d
> What I did is that I have a Task that reads from the Pipe and puts the
data in an IOBuffer, then read from that in the loop instead, it seems to
work.
That is what I do, with strings instead of IOBuffers. It does seem to work.
-- mb
On Wed, Feb 3, 2016 at 11:04 AM, STAR0SS
Tim,
Thanks for putting this tutorial together, it was an interesting read.
-- mb
On Mon, Feb 1, 2016 at 1:54 PM, Tim Holy wrote:
> It's come to my attention that some of the exciting capabilities of julia
> 0.4
> for indexing, iteration, and writing generic
Gaston can do that, too. Just be sure to use master instead of the latest
release; there's tons of bug fixes and improvements. The PDF documentation
is here: https://bitbucket.org/mbaz/gaston/downloads/gastondoc-0.5.5.pdf.
-- mb
On Mon, Feb 1, 2016 at 9:45 AM, Tom Breloff
I tend to just run Jupyter by itself from a command line, not from Julia.
Interrupting Julia's notebook() doesn't work reliably.
-- mb
On Fri, Jan 22, 2016 at 7:32 AM, Lutfullah Tomak
wrote:
> I have a julia script that runs IJulia
> as
>
> #!/bin/sh
> julia -e "using
ably
> negligible compared to the IO cost, and b) it’s actively being worked on
> <https://github.com/JuliaLang/julia/pull/13412> and will eventually be
> fast.
>
> // T
>
> On Tuesday, January 12, 2016 at 3:50:04 AM UTC+1, Miguel Bazdresch wrote:
>
> Tomas,
>
An alternative would be to interact with the sound card using sox (
http://sox.sourceforge.net/). In the past, I used sox from Octave to record
and play audio simultaneously. Let me know if you'd like to see the code; I
can probably dig it out of my old backups.
-- mb
On Sun, Jan 17, 2016 at
ete type, and you
> just want to switch it out for an instance with other field values. If you
> actually need to change the *type* of readnow, all bets are off and this
> trick won’t work.
>
> // T
>
> On Friday, January 8, 2016 at 9:28:02 PM UTC+1, Miguel Bazdresch wrote:
&g
Hello,
I'd be grateful if you could take a look at some code and suggest
improvements.
I'm trying to interact with a long-lived process (gnuplot). This process
reads commands from its STDIN; after each command is executed, it produces
output on either its STDOUT or STDERR. It's impossible to
Do you get different results using readavailable()? Maybe there isn't a
newline on the stream and readline() blocks waiting for it.
On Tue, Dec 8, 2015 at 2:51 PM, Colin Beckingham
wrote:
> I'm trying to launch a process from a Julia script. The process is a
> socket
I didn't think that section applied to my case, since I have two processes,
each reading/writing to a different pipe.
I've also tried to use IOBuffer() and IOStream(), but without any success.
Thanks,
-- mb
On Mon, Dec 7, 2015 at 8:34 AM, James Gilbert wrote:
> I think
Eventually I wish to capture both stdout and stderr; first I want to learn
to capture stdin using open(). And, you did mention stderr in your first
reply :)
Thanks for the link; I'm keeping an eye out on it, but in its current state
its not useful.
-- mb
On Mon, Dec 7, 2015 at 4:01 PM, James
Yes, but the problem is that readandwrite() does not provide access to
stderr (see https://github.com/JuliaLang/julia/issues/11824). That's why
I've been trying alternative solutions.
On Mon, Dec 7, 2015 at 1:17 PM, James Gilbert wrote:
> Turns out that there is a function
I need to run an external program and write to its STDIN, and read from its
STDOUT. I'm trying to do this using open(). Writing to its STDIN works fine
with the method below, but I cannot read from its STDOUT.
To simplify my tests, I wrote a simple C program called 'stdo' that
constantly
These are my thoughts exactly. I used Matlab because it was a convenient,
easy way to get results, but the warts in the design are real. Julia,
besides being convenient and easy, is a pleasure to program in.
-- mb
On Fri, Oct 23, 2015 at 5:41 PM, Andrew wrote:
> I don't
With this Julia code:
x = -2.34e-12;
for i in 1:5
x=-x*5000.
println("$i $x")
end
I get this output:
1 1.17e-8
2 -5.8506e-5
3 0.29254
4 -1462.50002
5 7.3125001e6
I don't think this is too bad. True, the output is a bit longer, but I
actually prefer
mulas
> in LaTeX, etc. So the plot itself is usually very simple, but I need to be
> able to make any change requested by my supervisor, or the journal editor,
> or the referee.
>
> Cheers,
> Daniel.
>
>
>
>
>>
>>
>> On Thursday, September 10, 2015, Migu
killing
> the shell window
>
> rd,wr=redirect_stderr();
> run(pipeline(ignorestatus(cmd), stdout=DevNull, stderr=rd))
>
> now if try to read from 'rd'
>
> readall(rd)# ---> IceAge
>
>
> sábado, 12 de Setembro de 2015 às 15:35:39 UTC+1, Miguel B
Personally, I'd prefer to just have an old-fashioned, LISTERV-type mailing
list. Yes, I'm old.
-- mb
On Wed, Sep 9, 2015 at 7:34 AM, Nils Gudat wrote:
> Was just thinking about this as first I had to try opening a thread here a
> couple of times before any posts were
The Segmentation Fault strongly suggests a glitch, not an Easter egg,
unfortunately... :)
On Tue, Sep 1, 2015 at 1:12 PM, wrote:
> Using 0.4:
>
> help?> mean
> search: mean mean! median median! SegmentationFault macroexpand
> module_parent Meta enumerate Enumerate
In terms of dependencies and size, Gaston is probably minimal; it depends
on gnuplot only, which is a small binary and readily distributed on Linux,
OS X and windows. It offers basic features only (but has 3-D plotting), but
this may be an advantage for a default package. It is also well
Works for me on Linux, with julia v0.3.10, and IJulia master.
-- mb
On Tue, Jun 30, 2015 at 9:00 PM, Gabriel Goh gabgo...@gmail.com wrote:
Hey everyone,
I've upgraded to Julia v0.3.10 and did the requisite Pkg.build(IJulia)
commands. After launching an IJulia notebook, the kernel keeps
You can make sure that there is data in `so` by looking at its 'bytes
waiting' field. If there is indeed data in the pipe, maybe there is no
newline character in it? Have you tried `readall` instead of `readline`?
-- mb
On Sat, Jun 27, 2015 at 8:45 AM, Laurent Bartholdi
To answer your question about Gaston first, when I wrote that code nearly 3
years ago, there was no infrastructure in julia to create pipes to external
processes. That's why I went with popen from the C standard library. I will
update that code, but I want to read from both Gnuplot's STDOUT and
dependencies
on Windows) fixing a typo in a configure flag which changed the way
libstdc++ deals with strings. C++ is filled with this nonsense, and even
ZMQ's author regrets writing ZMQ in C++ instead of C.
On Thursday, June 25, 2015 at 8:13:11 PM UTC-4, Miguel Bazdresch wrote:
It doesn't, at least
These issues may be relevant:
https://github.com/JuliaLang/ZMQ.jl/issues/83
https://github.com/JuliaLang/IJulia.jl/issues/323
-- mb
On Thu, Jun 25, 2015 at 9:37 AM, Grigoriy Isaev grigoriy.v.is...@gmail.com
wrote:
It seems that there is unfixed bug somewhere in Juno distribution. Latest
64
It doesn't, at least for me. ZMQ tests still segfault.
-- mb
On Thu, Jun 25, 2015 at 5:36 PM, Tony Kelman t...@kelman.net wrote:
0.3.10 (released yesterday) should fix this error.
On Thursday, June 25, 2015 at 10:02:09 AM UTC-4, Miguel Bazdresch wrote:
These issues may be relevant
.
Cheers,
Kevin
On Thursday, June 18, 2015, Miguel Bazdresch eorli...@gmail.com wrote:
Is there a way to read the spawned process' STDERR? Gnuplot likes to
write most output to it. I've tried
readandwrite(`gnuplot 21`)
but gnuplot interprets 21 as a filename and fails.
This, however
, and the process object itself.
Which *also* returns a tuple (but at least now you know).
See also http://blog.leahhanson.us/running-shell-commands-from-julia.html,
which has a full rundown of reading and writing from processes.
Cheers!
Kevin
On Wed, Jun 17, 2015 at 9:03 AM, Miguel
,
which has a full rundown of reading and writing from processes.
Cheers!
Kevin
On Wed, Jun 17, 2015 at 9:03 AM, Miguel Bazdresch eorli...@gmail.com
wrote:
Hello,
Gaston.jl is a plotting package based on gnuplot. Gnuplot is command-line
tool, so I send commands to it via a pipe. I open
Can you arrange the problem so that you send each CPU a few seconds of
work? The overhead would become negligible.
-- mb
On Wed, Jun 17, 2015 at 4:38 PM, Daniel Carrera dcarr...@gmail.com wrote:
Sadly, this function is pretty close to the real workload. I do n-body
simulations of planetary
Note that in most plotting packages, `plot(vec)` is interpreted as 1000
functions of 10 elements each. That is, when given a matrix as argument,
they plot the columns.
-- mb
On Tue, Jun 16, 2015 at 8:10 PM, Nelson Mok laishun@gmail.com wrote:
HI,
Please comment, how to plot the matrix
Hello,
Gaston.jl is a plotting package based on gnuplot. Gnuplot is command-line
tool, so I send commands to it via a pipe. I open the pipe (on Linux) with
a ccall to popen, and write gnuplot commands to the pipe using a ccall to
fputs.
This works fine, but I'm trying to see if Julia's native
I haven't tried Gaston on master, but it _may_ work, if you're on Linux or
MacOS.
-- mb
On Fri, Apr 24, 2015 at 6:58 AM, Tomas Lycken tomas.lyc...@gmail.com
wrote:
I git pull-ed and built Julia this morning, and I can't get any of PyPlot,
Winston or Gadfly or TextPlots to show me anything
This is great, and something I wanted to do but hadn't had time for. I'll
give it a try when I have a chance.
On Mon, Apr 20, 2015 at 10:22 AM, Jay Kickliter jay.kickli...@gmail.com
wrote:
I just pushed a rough draft gr-juliaffi
https://github.com/JayKickliter/gr-juliaffi to GitHub. It is not
20, 2015 at 11:37 AM, Jay Kickliter jay.kickli...@gmail.com
wrote:
Thanks. What OS are you using, and how did you install Julia/GNU Radio?
I'll attempt to fix any major problems before you try it out.
On Monday, April 20, 2015 at 9:33:18 AM UTC-6, Miguel Bazdresch wrote:
This is great
You can do 3-D plots with Gaston.jl, and rotate them with the mouse. I
haven't added the required interface to make it compatible with IJulia,
though. Even doing that, I doubt that the plot would still be interactive,
since that functionality is provided by Gnuplot.
-- mb
On Tue, Mar 3, 2015 at
On Matlab R2013b:
2*10.97 + 23.9985
ans =
45.9385
2*10.97 + 23.9985 == 45.9385
ans =
0
-- mb
On Tue, Nov 4, 2014 at 7:48 PM, Stefan Karpinski ste...@karpinski.org
wrote:
Some systems round their answers as John said but it's easy to check that
it's a lie:
R version 3.1.0
How could I force the type of gxs1 to be of an array of Float64?
The simplest way is:
gxs1 = Float64[g(x) for x in xs]
-- mb
On Mon, Nov 3, 2014 at 6:01 PM, Evan Pu evanthebou...@gmail.com wrote:
Consider the following interaction:
julia g(x) = 1 / (1 + x)
g (generic function with 1
but with a bigger
array you save a lot of time avoiding the conversion.
On Tuesday, October 14, 2014 3:14:38 AM UTC+3, Miguel Bazdresch wrote:
Just wanted to point out a little-known way to achieve the same with the
`kron` (Kronecker product) command:
julia x=[1 2 3 4]
1x4 Array{Int64,2}:
1
Just wanted to point out a little-known way to achieve the same with the
`kron` (Kronecker product) command:
julia x=[1 2 3 4]
1x4 Array{Int64,2}:
1 2 3 4
julia kron(x,int(ones(1,3)))
1x12 Array{Int64,2}:
1 1 1 2 2 2 3 3 3 4 4 4
-- mb
On Mon, Oct 13, 2014 at 6:05 PM, Rajn
Gaston can also do 3D plots. The docs are here:
https://bitbucket.org/mbaz/gaston/downloads/gastondoc-0.5.5.pdf
Having said that, PyPlot.jl is probably the way to go, unless you really
like gnuplot.
-- mb
On Wed, Oct 1, 2014 at 2:47 PM, Viral Shah vi...@mayin.org wrote:
Of course! PyPlot.jl
I just tried this (on 0.2.1):
julia (10//1)^(-2//1)
0.01
Is this expected?
-- mb
On Sun, Jun 8, 2014 at 6:36 PM, 'Stéphane Laurent' via julia-users
julia-users@googlegroups.com wrote:
julia (10//1)^(-2)
1//100
Would it be problematic to return a rational
for
I'm not sure I understand the question. Do you mean something like this?
inside_disc(x,y,radius) = sqrt(x^2+y^2)radius ? 1 : 0
-- mb
On Fri, Jun 6, 2014 at 8:28 PM, Zahirul ALAM zahirul.a...@gmail.com wrote:
I guess one can do a for loop. But how do I vectorize the code?
On Friday, 6 June
Weird indeed -- I have the same version and I get the same output as Matlab
(125.0 and 126.0).
julia versioninfo()
Julia Version 0.2.1
Commit e44b593* (2014-02-11 06:30 UTC)
Platform Info:
System: Linux (x86_64-unknown-linux-gnu)
WORD_SIZE: 64
BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH
In vim, you can do something like
imap \alphaTAB C-Vu03b1
to reproduce this behavior.
-- mb
On Thu, May 22, 2014 at 1:27 PM, Steven G. Johnson stevenj@gmail.comwrote:
A quick update for people who haven't been tracking git closely:
The Julia REPL (#6911), IJulia, and (soon) Emacs
*' - μ, 's*' - σ, 'Fm' - ♀), and honestly, you
wouldn't be using vim if you weren't into maximizing efficiency by learning
short cryptic commands.
On Thu, May 22, 2014, at 12:03 PM, Miguel Bazdresch wrote:
In vim, you can do something like
imap \alphaTAB C-Vu03b1
to reproduce this behavior
Some time ago I wrote a script to use pgfplots from octave/Matlab:
https://bitbucket.org/mbaz/printpgf/src/28cead667bda6ec745a4418bc408f7f712cf8433/inst/printpgf.m
It's very easy to use and I've used it for several publications. I tried it
to make it very easy to perfectly match fonts with the
The distributions.jl package extends Julia's random number capabilities,
it's worth a look:
https://github.com/JuliaStats/Distributions.jl
-- mb
On Thu, Apr 17, 2014 at 1:18 PM, X Du dux...@gmail.com wrote:
Thanks Isaiah,
It seems that srand([*rng*], *seed*) does not work, I always got
Can't it be done with a pipe? What I mean is, use the radio API to get the
data and store in a pipe. In julia, the main process would read from the
pipe and run your algorithms on it. If necessary, it could hand the data to
another process.
I've done something similar to read data from a sound
I agree that we should focus on getting something that works, and only then
focus on making it good and generic.
-- mb
On Mon, Apr 7, 2014 at 1:55 AM, Elliot Saba staticfl...@gmail.com wrote:
Jay, I'm a signal processing student and can help you out with the
multirate dsp if you want. Feel
I've been dreaming of writing a UHD package so that julia could talk to the
USRP. That'd be awesome, and probably not too hard, but I haven't found the
time.
-- mb
On Sun, Apr 6, 2014 at 5:19 PM, Elliot Saba staticfl...@gmail.com wrote:
This is pretty great! I've been wanting to write an
There is DSP.jl: http://dspjl.readthedocs.org/en/latest/index.html
On Tue, Mar 4, 2014 at 10:22 AM, Tobias Knopp
tobias.kn...@googlemail.comwrote:
I don't want to give a definate yes to it but will think a little bit how
such a package could look like.
My Cartesian macro foo is currently
I was worried about getting a little noise in the result, so I ran a
quick test in Matlab and Julia, and got almost exactly the same error. This
is the Matlab code:
Ts=0.01;
t=-10:Ts:10;
s=sinc(t);
sc=Ts*conv(s,s);
sc=sc(1000:3000);
sum((sc-s).*(sc-s))
ans =
0.3695
So, at least for
With Gaston, too, if that's any help.
-- mb
On Tue, Mar 4, 2014 at 8:16 PM, Steven G. Johnson stevenj@gmail.comwrote:
Panning and zooming work with PyPlot.
On Tuesday, March 4, 2014 7:05:07 PM UTC-5, Dan Becker wrote:
I just installed julia (v0.2.1) on windows, followed by winston.
Gaston supports output to GIF, which you could then assemble into an
animation with an independent tool.
https://github.com/mbaz/Gaston.jl
If possible, use the development version -- the latest release is getting a
bit long in the tooth.
-- mb
On Mon, Feb 24, 2014 at 11:57 AM, harven
Back in 2012 I did some preliminary work along these lines. The simulator
is described in this paper:
http://www.thinkmind.org/index.php?view=articlearticleid=simul_2012_1_20_50094
and the code is at: https://bitbucket.org/mbaz/chango
This simulator is able to interface to external devices; at
Laksh,
It works for me with julia 0.2 on Linux. I don't understand what this
message means:
INFO: Nothing to be done.
You shouldn't see that message. Do you get the same thing when loading
other packages? Can you delete or rename your .julia directory and try
adding the package again?
-- mb
the .julia directory but no luck. I tried both with the standard
installation of Julia as well as with Julia Studio.
On Monday, December 30, 2013 3:12:06 PM UTC-8, Miguel Bazdresch wrote:
Laksh,
It works for me with julia 0.2 on Linux. I don't understand what this
message means:
INFO: Nothing
72 matches
Mail list logo