Re: [julia-users] Re: Julia and the Tower of Babel

2016-10-09 Thread Michael Borregaard
Great to see this brought up here, and to read the constructive and thought-provoking responses from members of the Julia community. I feel this is highly important and I have thougt a lot about it recently, as I am writing an invited guest editorial for a leading ecological journal about how

[julia-users] Setting/getting field-like members with side effects

2016-10-09 Thread Bart Janssens
Hi all, I'm thinking about how to translate a Python interface that makes extensive use of __getattr__ and __setattr__ overloading to allow chaining a series of option values like this example: mysolver.linear_system.parameters.solver_type = "GMRES" Each time a . is encountered, the appropriate _

[julia-users] Re: Setting/getting field-like members with side effects

2016-10-09 Thread dnm
What about nested modules? Or unpure functions chained with the pipe operator? On Sunday, October 9, 2016 at 11:26:57 AM UTC-4, Bart Janssens wrote: > > Hi all, > > I'm thinking about how to translate a Python interface that makes > extensive use of __getattr__ and __setattr__ overloading to al

[julia-users] Re: julia-i18n: Translators and reviewer needed!

2016-10-09 Thread Lutfullah Tomak
Inspite of initial spur, it took a while for me finish hompage for Turkish page because of the new term starting at my university. I'm not an expert in translation it would be good if some other Turkish speaking user can check and give feedback for my crude translation. On Thursday, September

[julia-users] macro: with

2016-10-09 Thread Ben Lauwens
Hi Tom I am interested. I am building a macro mimicking how iterator blocks are transformed in a state-machine in C# (as an alternative to Tasks) and this is one of the (many) thinks I have to solve. Can you point me to the source? Thanks Ben

Re: [julia-users] macro: with

2016-10-09 Thread Tom Breloff
Heh... it took a google search to figure out where I put it. https://github.com/tbreloff/CTechCommon.jl/blob/master/src/macros.jl#L113-L155 On Sun, Oct 9, 2016 at 12:19 PM, Ben Lauwens wrote: > Hi Tom > > I am interested. I am building a macro mimicking how iterator blocks are > transformed in

[julia-users] Re: macro: with

2016-10-09 Thread Chris Rackauckas
What about Parameters.jl ? On Wednesday, September 7, 2016 at 7:23:47 AM UTC-7, Tom Breloff wrote: > > Hey all... I just threw together a quick macro to save some typing when > working with the fields of an object. Disclaimer: this should not be used > i

[julia-users] Re: Setting/getting field-like members with side effects

2016-10-09 Thread Chris Rackauckas
Why not use Symbols instead of strings here? On Sunday, October 9, 2016 at 8:26:57 AM UTC-7, Bart Janssens wrote: > > Hi all, > > I'm thinking about how to translate a Python interface that makes > extensive use of __getattr__ and __setattr__ overloading to allow chaining > a series of option va

Re: [julia-users] Re: macro: with

2016-10-09 Thread Tom Breloff
What about it? I don't think there's anything like this in Parameters. On Sun, Oct 9, 2016 at 1:27 PM, Chris Rackauckas wrote: > What about Parameters.jl ? > > > On Wednesday, September 7, 2016 at 7:23:47 AM UTC-7, Tom Breloff wrote: >> >> Hey all... I j

Re: [julia-users] Re: macro: with

2016-10-09 Thread Chris Rackauckas
It's a lot like unpacking a type, except instead of defining new variables for the unpacked values, your macro places the type instance designation (t. ...). On Sunday, October 9, 2016 at 10:55:45 AM UTC-7, Tom Breloff wrote: > > What about it? I don't think there's anything like this in Parame

[julia-users] Re: Setting/getting field-like members with side effects

2016-10-09 Thread Kristoffer Carlsson
That was one of the suggestions?

[julia-users] Re: Setting/getting field-like members with side effects

2016-10-09 Thread Chris Rackauckas
Missed that one, though it should be mysolver[:linear_system][:parameters][:solver_type] = :GMRES There's no reason for an algorithm choice to be a String. But this entire thing seems wrong-headed. The choice of the solver method should likely be done by dispatching on the solve method somehow.

Re: [julia-users] Setting/getting field-like members with side effects

2016-10-09 Thread Tom Breloff
I think that's great, but know that StochasticOptimization is still being designed and will likely change. On Sunday, October 9, 2016, Chris Rackauckas wrote: > Missed that one, though it should be > > mysolver[:linear_system][:parameters][:solver_type] = :GMRES > > There's no reason for an algo

Re: [julia-users] Re: Setting/getting field-like members with side effects

2016-10-09 Thread Bart Janssens
OK, thanks, so symbols are definitely preferred for the [] variant then? As for using dispatch, I am certainly all for designing a "proper" Julian interface, but the number of parameters here can be daunting, see e.g. here for a more complete example: https://github.com/barche/coolfluid3/blob/mast

[julia-users] Re: Warning since 0.5

2016-10-09 Thread Steven G. Johnson
On Saturday, October 8, 2016 at 5:09:19 PM UTC-4, digxx wrote: > > is f(x)=x^2 not an anonymous function?!?! > No, it has a name "f". An anonymous function is an expression like "x -> x^2" that creates a function object without binding it to a constant name.

[julia-users] Re: travis with dependency on scipy?

2016-10-09 Thread lapeyre . math122a
Me too. I mean, I found things worked much more smoothly after following this advice to use Conda. Also, Windows and OSX are supported immediately. Also, for my application, the Ubuntu package versions are very old, and out of date. This problem is solved as well. On Friday, October 7, 2016 at

[julia-users] redefining Base method for `show`

2016-10-09 Thread lapeyre . math122a
I want to change show for Symbol, Rational, and Bool. Till now, I simply overwrote the existing methods. This works great. I get what I want, even in warn and error and string interpolation, etc. It works flawlessly on v0.4, v0.5, and v0.6. But, this changes the behavior for everyone. So, I wan

Re: [julia-users] Re: Setting/getting field-like members with side effects

2016-10-09 Thread Chris Rackauckas
Yes, symbols would be preferred. Checking equality two symbols is quicker, but, more importantly, symbols are natural to Julia metaprogramming/expressions, meaning that if you use symbols then the expression is easier to generate via macros. Tom is getting shy, but really take a look at Stochas

Re: [julia-users] Re: Julia and the Tower of Babel

2016-10-09 Thread Jeffrey Sarnoff
__JuliaPraxis__ is on [github](https://github.com/JuliaPraxis) and [gitter](https://gitter.im/JuliaPraxis/Lobby), welcoming growth.

[julia-users] Re: Julia and the Tower of Babel

2016-10-09 Thread Jeffrey Sarnoff
JuliaPraxis is on github and gitter ... bring our praxes. On Saturday, October 8, 2016 at 8:42:05 AM UTC-4, Jeffrey Sarnoff wrote: > > I have created a new Organization on github: *JuliaPraxis.* > Everyone who has added to

[julia-users] Re: BinDeps / LoadError: Path /home/travis/.julia/v0.5/TALib/deps/src/ta-lib-0.4.0-src was not created successfully

2016-10-09 Thread Tony Kelman
It starts with / so it's an absolute path, and system-wide. Either don't include the leading /, or use one of the BinDeps "dir" functions to determine what to set prefix to. The autotools provider probably sets an okay default for that, but check what other packages do.