Re: [julia-users] Re: Calling all users of ParallelAccelerator.

2016-07-22 Thread DrTodd13
You may also want to look at another IntelLabs project on GitHub called Latte. It provides a DSL for deep neural networks in Julia. Todd - Original Message - From: pev...@gmail.com To: "julia-users" Sent: Friday, July 22, 2016 8:07:19 PM Subject:

[julia-users] Re: Which package downgrades other packages?

2016-07-22 Thread Jeffrey Sarnoff
+1 On Friday, July 22, 2016 at 10:24:30 PM UTC-4, Tony Kelman wrote: > > Maybe a useful function to write and submit to PkgDev would be go through > all installed packages, check the METADATA requires file for all the > installed versions and display a list of upper-bounded dependencies and >

[julia-users] Re: Calling all users of ParallelAccelerator.

2016-07-22 Thread pevnak
> > Hi Todd, > I have tried several times to use ParallelAccelerator to speed up my toy Neural Network library, but I never had any significant performance boost. I like the idea of the project a lot, sadly I was never able to fully utilise it. Best wishes, Tomas

[julia-users] Re: Error on indexing of UTF8String

2016-07-22 Thread Jeffrey Sarnoff
This is explained here unicode-and-utf-8 . You want to use `nextind`: name2="김아무개" name2[1] '김' nextind(name2,1) 4 name2[4] '아' name2[ nextind(name2,4) ] '무' name2[nextind(name2,nextind(name2,4))] '개' On Friday, July

Re: [julia-users] Re: Error precompiling on Windows 64 (julia 0.4.0 and 0.4.6)

2016-07-22 Thread Tony Kelman
You're probably thinking of linux sonames with dots. Windows doesn't have that, the dash in the name is a libtool convention for the best approximation you can get to allowing multiple versions of the library to be installed side by side, and different applications to link to different

[julia-users] Which package downgrades other packages?

2016-07-22 Thread Tony Kelman
Maybe a useful function to write and submit to PkgDev would be go through all installed packages, check the METADATA requires file for all the installed versions and display a list of upper-bounded dependencies and which package is responsible for each. A little bit of code might go a long way

[julia-users] Error on indexing of UTF8String

2016-07-22 Thread Joungmin Lee
Hi, I've been dealing with some strings including asian characters. In case of indexing of ASCIIString, there's no problem. But when dealing with a UTF8String, I could get only 1st and last characters. julia> name1="John Doe" "John Doe" julia> name2="김아무개" "김아무개" julia> name3="近藤雅子"

Re: [julia-users] Re: Installs .5.0 dev on unbuntu instead of .4.6

2016-07-22 Thread Fisher, Christopher
Thanks everyone. I couldn't figure out a solution based on installing the binaries (I'm new to linux) or the forum. In my case, John's code worked for me, except I had to omit --reinstall julia from the last command. I think part of this issue was that a file was left behind when I installed a

Re: [julia-users] Re: Strange performance issue in filling in a matrix column

2016-07-22 Thread Michael Prange
I'm new to Julia and do not know how to file a performance issue, but I am happy to do it. Can you point me to the right place? Sent from my phone > On Jul 22, 2016, at 18:09, Stefan Karpinski wrote: > > Can you file a performance issue? The built-in circshift should not

[julia-users] Re: Installs .5.0 dev on unbuntu instead of .4.6

2016-07-22 Thread John Best
Make sure you're using the release ppa (sudo add-apt-repository ppa:staticfloat/juliareleases)and not the nightlies ppa (sudo apt-add-repository ppa:staticfloat/julianightlies). Try sudo apt-add-repository --remove ppa:staticfloat/julianightlies sudo apt-add-repository

[julia-users] Re: Installs .5.0 dev on unbuntu instead of .4.6

2016-07-22 Thread cdm
this thread may be of interest to you: https://groups.google.com/forum/#!searchin/julia-users/PPA|sort:date/julia-users/7jl-NBGaaTI/VtFM7S5GBQAJ On Friday, July 22, 2016 at 4:43:21 PM UTC-7, Christopher Fisher wrote: > > Hi all- > > I'm trying reinstall Julia .4.6 on Ubuntu 16.04. For some

Re: [julia-users] Installs .5.0 dev on unbuntu instead of .4.6

2016-07-22 Thread Yichao Yu
On Fri, Jul 22, 2016 at 7:43 PM, Christopher Fisher wrote: > Hi all- > > I'm trying reinstall Julia .4.6 on Ubuntu 16.04. For some reason when I > follow the platform specific instructions, it installs .5.0 dev instead of > the stable version .4.6. Is there a way to install

[julia-users] Installs .5.0 dev on unbuntu instead of .4.6

2016-07-22 Thread Christopher Fisher
Hi all- I'm trying reinstall Julia .4.6 on Ubuntu 16.04. For some reason when I follow the platform specific instructions, it installs .5.0 dev instead of the stable version .4.6. Is there a way to install .4.6? Unfortunately, .5 dev is unstable

Re: [julia-users] Re: Error precompiling on Windows 64 (julia 0.4.0 and 0.4.6)

2016-07-22 Thread 'Bill Hart' via julia-users
Well, I thought that when you link against libgmp normally, it doesn't care that the filename is libgmp-16.dll. I thought the linker just took care of it for you, So I was surprised by this behaviour. I might just be confused though. On Friday, 22 July 2016 22:30:50 UTC+2, Tony Kelman wrote: >

Re: [julia-users] Pipeline interoperability with IOStream and IOBuffer

2016-07-22 Thread Steven G. Johnson
On Friday, July 22, 2016 at 8:55:44 AM UTC-4, Tom Breloff wrote: > > To be fair, he was told, in that issue, that julia-users was a more > appropriate place to ask this type of question. No, he was told to ask on julia-users about usage questions — in this case, if he can't figure out how

[julia-users] Which package downgrades other packages?

2016-07-22 Thread David Anthoff
I have a lot packages installed, but none pinned by myself. A whole bunch of packages are at versions that are not up-to-date (e.g. MathProgBase is at 0.4.3, way behind), even after Pkg.update(). I guess there must be some package that has an upper limit on one of its requirements, and that

Re: [julia-users] Re: Strange performance issue in filling in a matrix column

2016-07-22 Thread Stefan Karpinski
Can you file a performance issue? The built-in circshift should not have these performance issues. On Fri, Jul 22, 2016 at 4:18 PM, Michael Prange wrote: > I just discovered that Julia already has a function for circularly > shifting the data in an array: circshift(A,

Re: [julia-users] How to make an unsafe_string safe?

2016-07-22 Thread Jeffrey Sarnoff
Thank you.

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
Hi Viral, Yes, the binary image works without problems in Power8 ;). As expected, it complains that it cannot execute in Power7. I finished compiling in both power7 and power8 using the /tmp. The errors are still the same: Power8: -- CC src/gc.o CC src/gc-debug.o CC

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
HI VIral, I am also hoping that once IBM sees the potential of Julia+IBM Power for doing HPC and analytics, they will formally support the Julia development in the future just like what they did with the docker and other open source initiatives. On Fri, Jul 22, 2016 at 9:07 PM, Paulito Palmes

Re: [julia-users] Re: Error precompiling on Windows 64 (julia 0.4.0 and 0.4.6)

2016-07-22 Thread Tony Kelman
Fragile how? The -16 is part of the library name.

[julia-users] Re: Strange performance issue in filling in a matrix column

2016-07-22 Thread Michael Prange
I just discovered that Julia already has a function for circularly shifting the data in an array: circshift(A, shifts). However, its performance is worst of all. Using this new method, function fill_W4!{TF}(W::Matrix{TF}, icol::Int, w::Vector{TF}, ishift::Int) @assert(size(W,1) ==

[julia-users] How to make an unsafe_string safe?

2016-07-22 Thread Jeffrey Sarnoff
I have a ccall to a library that returns a C-string `cstr = ccall(__)`. I understand that v0.5/current practice is to do `jstr = unsafe_string(cstr)` upon obtaining `cstr`. The cstr is freed by another ccall. If I want to use or return that string as a Julia String type, do I need to do

Re: [julia-users] IBM Power port

2016-07-22 Thread Viral Shah
I am hoping we can have beta support from the 0.5 release onwards for sequential julia. We were able to do this work due to some small support from IBM. Hopefully, as more users use Julia on Power and HPC systems, there may be a way to sustain this through the right form of funding. For now, I

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
Hi Viral, Thanks. I have already informed the sysad to check the time sync of the servers to avoid future issues. I'll try to compile in local disks and get back to you. Yes, I understand it may take some work to create the bin image but highly appreciate the fact that Julia will run now in

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
great!!! thanks very much On Fri, Jul 22, 2016 at 8:49 PM, Viral Shah wrote: > I was able to sucessfully package julia. Files are here. You have to also > download the libtatlas.so and put it on your LD_LIBRARY_PATH. > > >

Re: [julia-users] IBM Power port

2016-07-22 Thread Viral Shah
I was able to sucessfully package julia. Files are here. You have to also download the libtatlas.so and put it on your LD_LIBRARY_PATH. https://drive.google.com/folderview?id=0B0rXlkvSbIfhR1RsbUV2VkpFMFk=sharing -viral > On Jul 22, 2016, at 2:51 PM, Viral Shah wrote: > >

Re: [julia-users] Re: Error precompiling on Windows 64 (julia 0.4.0 and 0.4.6)

2016-07-22 Thread 'Bill Hart' via julia-users
I found the issue. The dll is called libgmp-16.dll. But Julia expects the full name of the dll to be provided, i.e. libgmp-16, not just libgmp. This seems a bit fragile to me. Bill.

Re: [julia-users] Composite Type Array

2016-07-22 Thread Cameron McBride
On Fri, Jul 22, 2016 at 3:09 PM, Cameron McBride wrote: > julia> function get_event(v::Vector{ExampleEvent}, i) > n = length(v) > if i > n >for j in n:i >push!(v, ExampleEvent("",0,0,0,0,0,0)) # default values >

Re: [julia-users] Re: Working with DataFrame columns types that are Nullable

2016-07-22 Thread Jacob Quinn
You are correct. There are properties of NullableArrays required for proper data transfer/handling, but I still wanted users to get a familiar type back. I'm definitely helping out with https://github.com/JuliaStats/DataFrames.jl/pull/1008 to ensure DataFrames gets ported over as quickly as

Re: [julia-users] Composite Type Array

2016-07-22 Thread Jared Crean
I think what you are looking for is a constructor for your new type that uses incomplete initialization type ExampleEvent fld1::ASCIIString fld2::Int16 fld3::Int64 fld4::Int64 fld5::Int64 fld6::Int64 fld7::Int64 function

Re: [julia-users] IBM Power port

2016-07-22 Thread Viral Shah
It appears to me that you are building on some kind of a network filesystem and timestamps are getting messed up. Can you build in /tmp or somewhere, which may be guaranteed to have local storage and hence avoid these clock issues? If still doesn’t work, I will create some binaries and upload

Re: [julia-users] Re: Error precompiling on Windows 64 (julia 0.4.0 and 0.4.6)

2016-07-22 Thread 'Bill Hart' via julia-users
The errors are precisely the same if I invoke Julia with --inline=no. Bill. On 22 July 2016 at 20:25, Bill Hart wrote: > What's totally bizarre about this, apart from the lack of traceback > information, is that this is precisely the same as the code used in Julia

Re: [julia-users] Composite Type Array

2016-07-22 Thread maxent219
Thanks Cameron. What I wanted to do was assign values to fields but the example you posted requires me to pass values to all fields in my type. If I do: events[1] = ExampleEvent("asdf",123), julia throws an error since I need to pass values to ALL my type's fields. I don't always have to

[julia-users] Re: A workaround to use "." to access class member functions - is it unJulian?

2016-07-22 Thread Jeffrey Sarnoff
(big step ..!) On Friday, July 22, 2016 at 2:28:09 PM UTC-4, Zhong Pan wrote: > > OK, I admit, it's ugly. :-) > > Now I realize it's also wrong. In the example, the > inner-constructor-created member function split() cannot see member > variable "N"; it can only see parameter "n" that is

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
It caused a core-dump during linking ;( in Power7 ... CC src/cgmemmgr.o LINK usr/lib/libjulia.so.0.5.0 CC ui/repl.o LINK usr/bin/julia PERL base/pcre_h.jl PERL base/errno_h.jl PERL base/build_h.jl.phony PERL base/fenv_constants.jl PERL base/file_constants.jl

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
This problem might be specific to Redhat? Unfortunately, I don't have debian-based Power system running to test. On Fri, Jul 22, 2016 at 6:40 PM, Paulito Palmes wrote: > Here's the error using Power8: same error which happens during linking. > > Can you send me the tarballs

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
Here's the error using Power8: same error which happens during linking. Can you send me the tarballs of successfully compiled image in Power8? - LINK usr/lib/libjulia.so.0.5.0 make[1]: warning: Clock skew detected. Your build may be incomplete.

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
I'm compiling in both Power7 and Power8 and not yet finished. I started with make -j 20 but after some time, it had errors. Then I switch to make -j 1 but takes time to finish. I hope it will compile in both power7 and power8. I'll wait and try to check if I can fix some obvious errors.

[julia-users] Re: A workaround to use "." to access class member functions - is it unJulian?

2016-07-22 Thread Zhong Pan
OK, I admit, it's ugly. :-) Now I realize it's also wrong. In the example, the inner-constructor-created member function split() cannot see member variable "N"; it can only see parameter "n" that is passed in from outside. If the code changes N later on, the split() function will be using a

Re: [julia-users] Re: Error precompiling on Windows 64 (julia 0.4.0 and 0.4.6)

2016-07-22 Thread 'Bill Hart' via julia-users
What's totally bizarre about this, apart from the lack of traceback information, is that this is precisely the same as the code used in Julia itself in gmp.jl. Bill. On 22 July 2016 at 20:09, 'Bill Hart' via julia-users < julia-users@googlegroups.com> wrote: > I've narrowed it down to an issue

[julia-users] Re: Strange performance issue in filling in a matrix column

2016-07-22 Thread Michael Prange
Gunnar, Thank you for your explanation of the extra allocations and the tip about sub. I implemented a version with sub as fill_W3!: function fill_W3!{TF}(W::Matrix{TF}, icol::Int, w::Vector{TF}, ishift::Int) @assert(size(W,1) == length(w), "Dimension mismatch between W and w")

Re: [julia-users] Pipeline interoperability with IOStream and IOBuffer

2016-07-22 Thread William Wong
To add to that, this discussion had actually initially started out on Julia-Users https://groups.google.com/forum/#!searchin/julia-users/pipeline$20iostream/julia-users/-66VWszB-mM/b9wno137BgAJ I was also hoping that someone could help me with this question here: > In either case, it seems that

[julia-users] Re: Error precompiling on Windows 64 (julia 0.4.0 and 0.4.6)

2016-07-22 Thread 'Bill Hart' via julia-users
I've narrowed it down to an issue in the following snippet of code which is in __init__ in our package: ccall((:__gmp_set_memory_functions, libgmp), Void, (Ptr{Void},Ptr{Void},Ptr{Void}), cglobal(:jl_gc_counted_malloc), cglobal(:jl_gc_counted_realloc_with_old_size),

Re: [julia-users] Re: A workaround to use "." to access class member functions - is it unJulian?

2016-07-22 Thread Tom Breloff
In julia 0.4, I think this would be considered both slow and ugly. Since the improvements to anonymous functions in 0.5, it's now only ugly. :) I think you'll find a lot of benefit if you forget about OO-programming, and use multiple dispatch. "You must unlearn what you have learned!" On Fri,

Re: [julia-users] Composite Type Array

2016-07-22 Thread maxent219
Thanks Stefan! I thought it would be like declaring a struct array in c/c++ i.e. something like ExampleEvent events[2][1000]; Then set each field in the events array as I encounter the required value in my algo: e.g. events[1][1].fld1 = "ABC"; events[1][1].fld2 = 123; etc How do I access

[julia-users] Re: A workaround to use "." to access class member functions - is it unJulian?

2016-07-22 Thread Jeffrey Sarnoff
Too much riffle-raffle for the gain you mention (imo). On Friday, July 22, 2016 at 1:01:42 PM UTC-4, Zhong Pan wrote: > > Most people coming from the object-oriented programming (OOP) world are > used to using "." to access member methods/functions of a class. Consider > the following simple

[julia-users] A workaround to use "." to access class member functions - is it unJulian?

2016-07-22 Thread Zhong Pan
Most people coming from the object-oriented programming (OOP) world are used to using "." to access member methods/functions of a class. Consider the following simple example in Python that defines a class AA which has two members: an integer variable N to store the number of people attended,

[julia-users] Re: Error precompiling on Windows 64 (julia 0.4.0 and 0.4.6)

2016-07-22 Thread 'Bill Hart' via julia-users
I think there is a access violation occurring in one of the dlls we are loading in __init__. However, these are precisely the same dlls we used in the old version of Nemo, so I'm quite puzzled how they are causing an access violation just because we are using a later version of Nemo. I'll have

[julia-users] Re: Error precompiling on Windows 64 (julia 0.4.0 and 0.4.6)

2016-07-22 Thread Daniel Høegh
You could try to run Julia with the `--inline=no` flag to see if you get more debug information.

[julia-users] Re: Error precompiling on Windows 64 (julia 0.4.0 and 0.4.6)

2016-07-22 Thread 'Bill Hart' via julia-users
Here are some other things I tried: 1) Run Julia as administrator : no change 2) turn off precompilation : still doesn't work, error message below [2] That's the entire error message. There's no useful diagnostic information to suggest what might have gone wrong at all. Bill. [2]

Re: [julia-users] IBM Power port

2016-07-22 Thread Viral Shah
Did it go through? I usually build with make -j 20 on the machines that have enough cores. Let me know if you still want me to create the tarball. Using ATLAS makes the whole thing a bit nonstandard for creating distributions, but I’ll see what I can do if needed. -viral > On Jul 22, 2016, at

[julia-users] Re: FFT, PSD and Windowing functions

2016-07-22 Thread Islam Badreldin
Hi Yared, Please see below,, On Thursday, July 21, 2016 at 11:19:44 AM UTC-4, Yared Melese wrote: > Hi Islam, > > Thanks for your input > > I was able to find all windowing functions; however, there is nothing > about PSD ( power spectral density). In python and matlab, there is > function

[julia-users] Error precompiling on Windows 64 (julia 0.4.0 and 0.4.6)

2016-07-22 Thread 'Bill Hart' via julia-users
I just tried to run the latest (master) version of our Nemo package on Windows 64 using Julia 0.4.6 and after many ambiguity warnings (which are harmless) it bombs out with the message below [1]. What we have tried: 1) Building the old version of Nemo with Julia 0.4.6 : works OK 2) Building

[julia-users] help with integrating websockets and protobuf

2016-07-22 Thread Jon Norberg
just to check that there is no problem in the formats, the following does send a ljulia-protobuf formatted message to the html-client but somewhat indirectly msg = read(client) iob = PipeBuffer(); write(iob,msg) test = readproto(iob,com())

[julia-users] help with integrating websockets and protobuf

2016-07-22 Thread Jon Norberg
Dear julia community. I can't figure out whats wrong here. I have a web socket implementation that works just fine without using protobuf on the julsa/websocket side (in fact, the html-client does send a protobuf array which just gets sent back without unpacking and packing on the julia web

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
Ah, forgot to update Make.user On Fri, Jul 22, 2016 at 3:50 PM, Paulito Palmes wrote: > Hi, > > Got this error using Power7: Linux abc.com 3.10.0-327.4.5.el7.ppc64 #1 > SMP Thu Jan 21 04:12:40 EST 2016 ppc64 ppc64 ppc64 GNU/Linux > > Red Hat Enterprise Linux Server

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
Hi Viral, uname -a is: > Linux abc.com 3.10.0-327.18.2.el7.ppc64le #1 SMP Fri Apr 8 05:10:45 EDT 2016 ppc64le ppc64le ppc64le GNU/Linux and using Power8: Red Hat Enterprise Linux Server release 7.2 (Maipo) Can you send me the tarball image of Julia compiled in Power8? I would like to test it

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
Hi, Got this error using Power7: Linux abc.com 3.10.0-327.4.5.el7.ppc64 #1 SMP Thu Jan 21 04:12:40 EST 2016 ppc64 ppc64 ppc64 GNU/Linux Red Hat Enterprise Linux Server release 7.2 (Maipo) -- make -C build/openblas-12ab1804b6ebcd38b26960d65d254314d8bc33d6/ CC=gcc FC=gfortran

[julia-users] Re: Working with DataFrame columns types that are Nullable

2016-07-22 Thread Evan Fields
As far as I know, DataFrames are only backed by DataArrays. (I believe there's current work being done to upgrade the speed and type stability of DataFrames, in part by using Nullables.) It might be helpful to write a little convenience function like f(n) = isnull(n) ? NA : get(n) I will say

[julia-users] Re: accessing an expression's global scope from macro

2016-07-22 Thread Fábio Cardeal
Clearly the ingredient missing here is some evil type magic... Hint: immutable SelfFunction f::Function end selfcall(f::SelfFunction, t::MyType, args...) = f(t, args...) selfcall(f, t::MyType, args...) = f(args...) const inc2 = SelfFunction((t::MyType) -> begin selfcall(inc,

Re: [julia-users] IBM Power port

2016-07-22 Thread Viral Shah
Not sure what to do here. Is the filesystem NFS or something? Perhaps just try building again with make -j 1. What is uname -a? -viral On Jul 22, 2016 8:52 AM, "Paulito Palmes" wrote: > Hi, > > I'm compiling using Red Hat Enterprise Linux Server release 7.2 in Power8 > and

Re: [julia-users] Pipeline interoperability with IOStream and IOBuffer

2016-07-22 Thread Tom Breloff
To be fair, he was told, in that issue, that julia-users was a more appropriate place to ask this type of question. On Friday, July 22, 2016, Steven G. Johnson wrote: > > > On Thursday, July 21, 2016 at 6:09:12 PM UTC-4, William Wong wrote: >> >> I'm trying to continue

Re: [julia-users] IBM Power port

2016-07-22 Thread Paulito Palmes
Hi, I'm compiling using Red Hat Enterprise Linux Server release 7.2 in Power8 and I got this error: ./julia/usr/lib64/libunwind*.a: No such file or directory the make process didn't create usr/lib64 and the libunwind*.a are in usr/lib I created the links of libunwind*.a in usr/lib64 but got

[julia-users] Re: I can't believe this spped-up !

2016-07-22 Thread Roger Whitney
Instead of using tic toc use @time to time your loops. You will find that in your sequential loop you are allocating a lot of memory, while the @parallel loop does not. The difference in time is due to the memory allocation. One of my students ran into this earlier this week and that was the

[julia-users] Re: Array of vectors in type definition

2016-07-22 Thread Jussi Piitulainen
type croc teeth :: Int64 legs :: Int64 sons :: Vector{Matrix{Float64}} croc() = new(0,0, Vector{Matrix{Float64}}()) croc(th, gs) = new(th, gs, Vector{Matrix{Float64}}()) croc(th, gs, ns) = new(th, gs, ns) end reptile = croc() reptile.teeth = 4 reptile.legs = 80 push!(reptile.sons,

[julia-users] Re: Pipeline interoperability with IOStream and IOBuffer

2016-07-22 Thread Steven G. Johnson
On Thursday, July 21, 2016 at 6:09:12 PM UTC-4, William Wong wrote: > > I'm trying to continue the discussion of > https://github.com/JuliaLang/julia/issues/15479 > The github issue is the appropriate place for discussion; it's not helpful to split the discussion into two separate forums.

[julia-users] Re: Array of vectors in type definition

2016-07-22 Thread Ferran Mazzanti
Ok all tests seem to fail, sorry. Jossi doing what you say directly works, but trying to wrap up things in a type deffinition either fails, or fails when I try to push!() things. Could you please be so kind to fill the whole example? Something like: type croc() teeth :: Int64 legs :: Int64

[julia-users] Re: Array of vectors in type definition

2016-07-22 Thread Ferran Mazzanti
Thanks Jussi for being so helpful :) I'll try that and check. Then I'll carefully think about all this to see what can I learn from here :) Best regards, Ferran.

Re: [julia-users] Re: accessing an expression's global scope from macro

2016-07-22 Thread Mauro
On Fri, 2016-07-22 at 10:18, Marius Millea wrote: > Yea, thats a good point. Granted for my purpose I'm never going to be > redefining these types mid program. I suppose one might extend your @unpack > to work on an expression and do the substitution recursively like my

Re: [julia-users] accessing an expression's global scope from macro

2016-07-22 Thread Yichao Yu
>> You should not do this. It is possible to access the current module >> but you don't have any scope information. > > > Do you mean that its possible to get the module where the expression (not > the macro) is defined? If so, how do I do that? > `current_module()` is the module the expression

Re: [julia-users] A foolproof question about ylim

2016-07-22 Thread chobbes158
Terrific! As a stranger to python, I've never thought that get and set methods are using the same keyword. Thanks! On Friday, July 22, 2016 at 12:09:17 AM UTC+1, Yichao Yu wrote: > > On Thu, Jul 21, 2016 at 7:03 PM, > wrote: > > > > > > How can I get ylim when using

[julia-users] Re: Array of vectors in type definition

2016-07-22 Thread Jussi Piitulainen
perjantai 22. heinäkuuta 2016 12.26.58 UTC+3 Jussi Piitulainen kirjoitti: > > I'm not sure how the square brackets would be used if you wanted a matrix > of matrices, but you could at least start with an empty one by writing > Matrix{Matrix{Float64}}(). And for an empty vector of matrices, as

[julia-users] Re: Array of vectors in type definition

2016-07-22 Thread Jussi Piitulainen
perjantai 22. heinäkuuta 2016 11.28.58 UTC+3 Ferran Mazzanti kirjoitti: > > Sorry for being so noob once again, but I'm getting close without getting > actually to it. > Could somebody tell me please how should I change the previous definition > of caw() as given by Jussi to make room > for a

[julia-users] Re: Array of vectors in type definition

2016-07-22 Thread Ferran Mazzanti
Sorry for being so noob once again, but I'm getting close without getting actually to it. Could somebody tell me please how should I change the previous definition of caw() as given by Jussi to make room for a Vector of Arrays (I can fix them to dimension 2) instead of a Vector of Vector? I'd

Re: [julia-users] Re: accessing an expression's global scope from macro

2016-07-22 Thread Marius Millea
Yea, thats a good point. Granted for my purpose I'm never going to be redefining these types mid program. I suppose one might extend your @unpack to work on an expression and do the substitution recursively like my thing does, then you could write, @unpack aa: a function(x,aa:A) sin(2pi/a*x)

Re: [julia-users] Re: accessing an expression's global scope from macro

2016-07-22 Thread Mauro
On Fri, 2016-07-22 at 01:02, Marius Millea wrote: >> FYI Mauro's package has something similar >> . >> > > Some interesting stuff in there, thanks! The problem with your `@self` and with Parameters.jl's

Re: [julia-users] accessing an expression's global scope from macro

2016-07-22 Thread Marius Millea
On Thu, Jul 21, 2016 at 10:33 PM, Yichao Yu wrote: > On Thu, Jul 21, 2016 at 4:01 PM, Marius Millea > wrote: > > In an attempt to make some numerical code (ie something thats basically > just > > a bunch of equations) more readable, I am trying to