Better HN
topnewbestaskshowjobs
Log inSign up

3JPLW

3,234 karma · joined Feb 3, 2012 (14y ago) · 682 submissions

Submissions

comment 5y ago · link · parent

FWIW, Julia does segment its method tables into multiple layers depending upon size and type. Multiple dispatch is a strict superset of single-dispatch, and indeed the first layer is just a dictionary/hash table lookup on the first argument. If there's only one result there, you're done (and have the same ~cost for the same ~complexity).

comment 5y ago · link · parent

Is your home folder on a network drive?

comment 5y ago · link · parent

Thanks for the report:

https://github.com/JuliaLang/julia/issues/40190

Edit: it's now building:

https://github.com/JuliaLang/docs.julialang.org/runs/2196972...

comment 5y ago · link · parent

That same format string is used in multiple places, and unfortunately I don't think the text engine they expose to us is smart enough to do the ordinal 1st 2nd 3rd thing.

Edit: oh, we can do that. Changed experimentally.

comment 5y ago · link · parent

The problem is a minor placement issue for the `@simd` macro: https://github.com/kostya/benchmarks/pull/317

comment 5y ago · link · parent

As an administrator at Julia's discourse, I'd be really curious if this was the reason. Discourse's default "short date" format is super problematic. By default, they display something from 5 days ago as `Mar 20` and something from a year ago as `Mar '20`. We've changed that to have the year+ old posts display as `Mar 2020`, but maybe we should also change the recent display to be something different; maybe `20 Mar`? The UI doesn't give us too much space, unfortunately.

comment 5y ago · link · parent

The feature I'm most excited about is the parallel — and automatic — precompilation. Combined with the iterative latency improvements, Julia 1.6 has far fewer coffee breaks.

8.

Julia 1.6 Highlights(julialang.org ↗)

410 points · by mbauman · 5y ago · 214 comments

comment 5y ago · link · parent

A thread from 2020 (v2 RC 1): https://news.ycombinator.com/item?id=22030928

2015: https://news.ycombinator.com/item?id=9315152

2014: https://news.ycombinator.com/item?id=7381877

2011: https://news.ycombinator.com/item?id=2784515

comment 5y ago · link · parent

Benefits are highly regional. Where I live, the current latest sunrise is 8:06 am on December 5. I can't imagine a sunrise after 9am being very fun.

comment 5y ago · link · parent

Sure, there is a subset of behaviors for which this style makes sense, but it's just as well supported by simply defining your own functions alongside the struct.

comment 5y ago · link · parent

Julia will be able to generate c-compatible .so/.dlls in a not so distant future.

comment 5y ago · link · parent

I actually find it far more linguistic, that is, more akin to natural languages.

In my view, it's not multiple dispatch per se that is the bigger departure from traditional OOP, it's the fact that methods are no longer contained in the classes. Julia draws a separation between data (structs: the nouns) and behaviors (functions: the verbs). Traditional OOP never really made sense to me; why should each class define and own its own methods? It feels far more sensible to me to just have global behaviors that are well defined. Those verbs can sometimes apply to _anything_ (leaning on more rudimentary operations that you need to define; duck-typing), and sometimes they require you to explicitly define your behavior, and sometimes you just want to add an additional optimization that's available in your particular situation.

Once you have that mental model down, multiple dispatch is just how Julia chooses which method to call... and it's really not much different from single-dispatch.

comment 5y ago · link · parent

Yeah, you (used to?) be able to do multi-room audio with the original Airplay, but it was only supported from Macs. iOS did not support it.

comment 5y ago · link · parent

Lots of the sciml.ai packages and documentation use Weave — you can look there for some examples. Here's one:

https://diffeq.sciml.ai/stable/tutorials/sde_example/

comment 5y ago · link · parent

I encourage folks to actually read the linked article instead of basing their commentary on the shoddy title.

https://www.nature.com/articles/s41928-020-00523-3

Abstract:

> Resistive memory technologies could be used to create intelligent systems that learn locally at the edge. However, current approaches typically use learning algorithms that cannot be reconciled with the intrinsic non-idealities of resistive memory, particularly cycle-to-cycle variability. Here, we report a machine learning scheme that exploits memristor variability to implement Markov chain Monte Carlo sampling in a fabricated array of 16,384 devices configured as a Bayesian machine learning model. We apply the approach experimentally to carry out malignant tissue recognition and heart arrhythmia detection tasks, and, using a calibrated simulator, address the cartpole reinforcement learning task. Our approach demonstrates robustness to device degradation at ten million endurance cycles, and, based on circuit and system-level simulations, the total energy required to train the models is estimated to be on the order of microjoules, which is notably lower than in complementary metal– oxide–semiconductor (CMOS)-based approaches.

17.

The team shaking up climate models(csmonitor.com ↗)

1 points · by 3JPLW · 5y ago · discuss

comment 5y ago · link · parent

> No, it mostly affects execution time.

Citation needed. Yes, the -1 appears in the source code. It might even appear in the intermediate representation. It'll even show up in the assembly for multidimensional arrays (but it'll all get folded into a single `mov` assembly for vectors).

But I dare you to actually demonstrate a performance difference. Compared to a memory access, a `dec` is free.

comment 5y ago · link · parent

Or how about just waiting until it gets merged and officially adopted?

comment 6y ago · link · parent

From that study:

> Limitations: ... no assessment of whether masks could decrease disease transmission from mask wearers to others.

This has always been the main motivation for mask wearing, but the study you cite didn't attempt to answer it.

comment 6y ago · link · parent

Yeah, but this is a laptop chip at ~20W. Of course it's not going to compete with a 16-core 120W monster.

Getting 1/4 of the performance with 1/4 of the (high perf) cores and 1/6 of the power is very impressive.

comment 6y ago · link · parent

Poor response, as pandemic safety 101 would prevent this:

- wash your hands

- wear a mask

- practice social distancing

- avoid extended periods indoors with non-household members

https://www.cdc.gov/coronavirus/2019-ncov/prevent-getting-si...

comment 6y ago · link · parent

It's not just about protecting you, though. It's also about protecting our limited healthcare resources.

Every year I get the flu shot to protect me, you, and our shared healthcare.

comment 6y ago · link · parent

I'm not "free" to ignore stop signs, stop lights, and speed limits. They impact my freedom to drive as I'd wish -- because otherwise I might hurt you.

I'm not "free" to start cooking commercially out of my home kitchen without inspections and licensing. This impacts my ability to earn an income -- because otherwise I might make you sick.

It's public health risk mitigation. We do it all the time.

comment 6y ago · link · parent

This is a good resource for thinking around limiting transmission risks:

https://english.elpais.com/society/2020-10-28/a-room-a-bar-a...

comment 6y ago · link · parent

This is why speed limits are prudent.

This is why masks and gathering limits are prudent.

comment 6y ago · link · parent

Some of the NaN-handling issues are unique, but the compiler availability itself is still a problem.

https://twitter.com/StefanKarpinski/status/12929837172128931...

Since then, GCC has stepped up with this out-of-tree build, but it's still not 100% to my knowledge.

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96168

comment 6y ago · link · parent

Which is likely why there are some "7 core" GPU M1 chips.

comment 6y ago · link · parent

Especially given this:

> That 1948 study of 43 machines in Detroit showed ranges from 16 to 75 roentgens per minute. In 1946, the American Standards Association had issued a safety code for industrial use of X-rays, limiting exposure to 0.1 R per day.

I'd be curious how much a typical modern dental x-ray emits, but we no longer measure in roentgens these days as we have better measures of the actual dose (sieverts).

12345
23