Hacker News new | past | comments | ask | show | jobs | submit | Epholys's comments login

To complete the TL;DR : the safe Rust code is at 97% the speed of the C code, if keeping manual vectorization.


No, the Rust code is at 97% of the RUNTIME of the C code (https://cliffle.com/p/dangerust/5/#evaluation) when keeping the manual vectorization.


To complete the completion of the TL;DR : the 95% safe Rust Code using auto vectorization is even slightly faster than the C code.


The 95% safe Rust Code does not use any auto-vectorization (https://cliffle.com/p/dangerust/5/nbody-5.rs)

Only the 100% Rust-safe implementation uses auto-vectorization and is at 0.73% of the RUNTIME of the C code. (https://cliffle.com/p/dangerust/6/#performance-evaluation)


*73%


I don't have an inner voice, it's just completely abstract thoughts. I "feel" the interrogation about a subject, just without words.


So if I ask you to form an image of a song, (or recall it in your mind): the "happy birthday" song. How vivid or clear is it? Do you have no clarity, some, or lots? is it vivid as the actual sound as if you were hearing it in real life? Do you notice the tune as well as the words?

Now change this image of happy birthday so that it's now a childrens choir singing it. Now change it so its by a bunch of cynical unix grey beards singing it in a convention.

How easy was it to change this image? Did changing it affect the clarity?


Wow, these questions are really interesting, I've never thought about it!

For my favorite songs, I can recall it perfectly... But I don't hear it at all as if I was hearing it in real life. In fact, I don't know how to describe how vivid it is. Maybe I don't hear it at all? But I can sing these songs (out loud) without a problem.

However, I seem to be incapable of changing some elements about it. I can't seem to be able to make it faster, slower, change the singer, or the instruments. But, when I sing it out loud, I can of course modify it.

For "Happy birthday" (well, in my native language), it's really weird. Because I don't have a specific song in mind, I can follow the words, the tune, but I don't "feel" the voice of a specific singer. And I'm incapable to change this recall to different voices, like children or grown men. But if I listen to a version sung by these people, I can recall it after (until I forget).

Thanks again for these questions, I was aware of my lack of inner voice, my difficulties of a "inner sight" (that's a whole other can of worms), but I never applied this interrogations to a "inner hearing".


I got and adapted the questions from a survey about these issues but I've been trying to get the question right as we tend to use language which presupposes things.

I like this one as it asks to form an image and asks about clarity. The image is about hearing. So it crosses both parts.

Another example would be to form an image of a telemarketer on the telephone. Change the accent. Introduce line distortion.

For me it's in the middle. Happy birthday is clear to visualise and I can follow the tune. it's not very vivid but it's like I'm singing to myself with my mouth shut. I don't have a mental "visual" image of the song by default. When changing it the imagery appears a bit more but the focus is on the sound. I can easily change it to children's voices, the unix greybeards is more difficult as it requires me working out what they would sound like including spatial echoes from the auditorium. I find the resulting image (which is clearer than the children) is amusing.


Ha, interesting! I don't have the control you have on my inner hearing. For a song I love, I can like sing along with my mouth shut, not only the voices, but also the instruments. Strangely, it's hard to have the complete song at the same time (voice + instruments), but I suspect it's more of a skill issue, as I seem to be able to do it faintly.

I'm not envious of the people who have an inescapable inner voice. I think it would hinder my thoughts, the speed of it, and the ability to think abstractly. It's not totally baseless, because I can force myself to have an inner voice, but it's a conscious effort. Sometimes useful if I need to clarify my thoughts. On the same note, not having a inner voice makes it really difficult sometimes to put my emotions and thoughts into words.

But I'm really jealous about anyone that can clearly conjure images, "videos", and sounds in their mind, I feel like I have a big disadvantage if I want to learn to draw, 3D model, or play an instrument.


People speak of these things in term of identity, but I wonder how true that is. I could easily imagine (pun intended) these are more akin to skills, that can be improved with practice.

Actually now that I think about it, I do know that this is a well-known phenomenon in the chess world. Newcomers are unable to to play blind-chess. But experienced players say that they gradually learned how to do it. How it started as a really blurry picture of just a small part of the board, and how they gradually got better at remembering and visualizing the whole board at the same and were able to play full games with a blindfold.


You're referring to thinking proactively. Is your inner narrative proactive or reactive?


I love L-Systems! Really simple concept and implementation, but a huge variety of results and extensions.

In parallel of my studies, I created some years ago on the side an interactive app for generating and coloring L-Systems : https://epholys.itch.io/lsys . It's a bit rough, but I created a lot of interesting trees (all here : https://imgur.com/a/0Rx7uln) and included them as a zip file alongside the app.


I love easy effects! I have a crappy webcam/mic combo, and the noise reduction filter is very performant, the people I'm speaking to are really grateful about it


Further down in this article, Kevin Hartnett wrote:

> The Euler equations are not a literal description of a real-world fluid. They include several nonphysical assumptions. For example, the equations only work if internal currents within a fluid don’t generate friction as they move past each other. They also assume that fluids are “incompressible,” meaning that under the rules of the Euler equations, you can’t squeeze a fluid into a smaller space than the one it already occupies. > [...] > These unnatural provisos led the mathematician and physicist John von Neumann to quip that the equations model “dry water.” To model the motion of a more realistic fluid with internal friction (or viscosity), researchers use the Navier-Stokes equations instead.

So it seems they know what they are writing about, at least more than you supposed.


I'm always happy to see L-Systems! I find them really awesome, the base principle is very simple: string rewriting. But the results can really be impressive for such a simple concept.

I can't help but do a shameless self-plug: I'm developing an interactive L-System generator : https://github.com/epholys/procgen.

Here is a little demo: https://www.reddit.com/r/proceduralgeneration/comments/b4kpa...

And here are the L-System I've produced: https://imgur.com/a/0Rx7uln


I've been seeing yours on reddit lately, very nice stuff!


There is a lot of evidence indicating that the megafauna extinction was principally due to the human hunters. Here is a very good (but long) Twitter thread by a biologist explaining it in detail: https://twitter.com/DRMegafauna/status/1084896526151942145


It's really heartwarming to have progress in this field of medicine! I feel anxious just imagining being unable to move my arms.

But there's a catch:

> Despite these achievements, nerve transfer surgery still has some limitations. For the best results nerve transfers should ideally be performed within 6-12 months of injury.

I hope this method will progress to have a much longer span of time allowing this surgery.


Th limitation is due to changes in the distribution of receptors on the muscle, and the muscles health, once it loses neuro stimulation.

Progress here is something I’m very optimistic about.


>I hope this method will progress to have a much longer span of time allowing this surgery.

I think it becoming cheap/common enough that 6-12mo is not a limitation in practice would be a far better outcome.


The problem isn't with treating new injuries. There are a lot of paraplegics in the world today who were injured a long time ago, and it would be nice to fix them...

A much harder problem, I'm afraid.


I can't help but to do a shameless plug: the author also have an article about L-Systems [0] which inspired me to create my own interactive generator [1]. There isn't a release yet, but it is mainly functional and I already have some awesome results! Here is a video demo [2] and some produced L-Systems [3].

[0] http://blog.rabidgremlin.com/2014/12/09/procedural-content-g... [1] https://github.com/epholys/procgen [2] https://www.reddit.com/r/proceduralgeneration/comments/b4kpa... [3] https://imgur.com/a/0Rx7uln


Yeah, that's the first solution that popped in my mind too. I think it needs just a special case at the beginning to check if the first paren is not a closing one.

EDIT: yep, after reading the comments below I see that I really should have put just a little more thought before dismissing this as too trivial to think about.


The stack solution checks that the stack is non-empty before popping.

The counter solution simply needs to check that the counter is non-zero before decrementing.

All cases then work perfectly.


What you actually need is to check if the count ever goes negative.


A test case: ())(


Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: