Better HN
topnewbestaskshowjobs
Log inSign up

andersource

1,192 karma · joined Jul 24, 2019 (7y ago) · 266 submissions

https://andersource.dev/

hi@andersource.dev

Have a nonstandard optimization problem? Could use an interactive visualization to explore complex data? I'd love to hear about it!

Submissions

comment 5y ago · link · parent

Thanks, and really happy you enjoyed it!

> The only thing I did not like was that for certain puzzles, such as the Ying-Yang one, coming up with an idea that will solve the puzzle is quite straight forward, but figuring out the parameters you used for some of the curves can take a long time.

Yeah, I know that's an annoying issue. I've been trying to think how to implement a good fuzzy judge, but so far everything I have will either forgive mistakes in small but important components or require a major restructuring of the game. Would be happy to hear if you have suggestions for that :)

comment 5y ago · link · parent

Hey, thanks a lot! And neat workaround :)

comment 5y ago · link · parent

Hey, thanks!

That looks really cool, of course you can incorporate a puzzle!

I don't have data on solution times, but I think it's very different for an individually-solved series of similar puzzles and a group escape room-style puzzle. My recommendation would be to prefer a puzzle that requires an "Aha!" moment and from there is relatively quick, rather than a more meticulous one that requires tweaking parameters and messing around a lot.

comment 5y ago · link · parent

Thanks! Turing Tumble looks awesome

comment 5y ago · link · parent

Hey! There isn't a sandbox, this is indeed just a javascript eval. It's essentially the same as running code on the devtools console, except with an editor UI and wrapped in way that saves the hassle of messing with the DOM.

comment 5y ago · link · parent

Thanks! Yeah it's problematic on mobile, I think writing code on mobile will be cumbersome anyway

187.

Show HN: Checkerboard Programming – write code to match checkerboard patterns(checkerboardprogramming.com ↗)

40 points · by andersource · 5y ago · 20 comments

188.

Inigo Quilez – Live Coding Improv (2011) [video](youtube.com ↗)

2 points · by andersource · 5y ago · discuss

comment 5y ago · link · parent

I was perplexed as well. It seems to be Jane Austen's "Pride and Prejudice" written at the very top of the library punch cards.

comment 5y ago · link · parent

I would say at latest when people convicted because of it had their names cleared - https://www.bbc.com/news/business-56859357

comment 5y ago · link · parent

Most of the time, but it can, and I think that's the issue a lot of people have with it.

https://twitter.com/mitsuhiko/status/1410886329924194309

https://news.ycombinator.com/item?id=27710287

comment 5y ago · link · parent

You can see the trailer for the game they developed here: https://www.youtube.com/watch?v=F2J11YFTsAE

> the first games were played on machines that only had text mode

This is also mentioned in the video, the author's aim seems to be to describe all elements of the game with natural language (e.g. rogue doesn't count, it uses text but in a graphical form).

comment 5y ago · link · parent

There's a beautiful visualization of prime factorization using UMAP: https://johnhw.github.io/umap_primes/index.md.html. I recommend watching the video!

comment 5y ago · link · parent

Gladly!

> So is "T" and "N" conventionally used in numerical optimization as the transform "variables" (like X and Y are in calculus)?

Not really, numerical optimization offers a general toolbox for various problems, which are usually defined based on domain-specific notation and concepts. So the concept of a transformation like the one described in the article is not general to numerical optimization, but specific to the optimization being done here. That being said, when talking about techniques, theorems and algorithms in numeric optimization there are conventions. So you usually move between the more theory-oriented notation to a domain-specific notation (in the article I mostly used the domain-specific, lazy notation I chose).

Bear in mind that my perspective is not very academic so I might feel less strongly about (and be less aware of) rigorous mathematical conventions.

comment 5y ago · link · parent

Hey!

I is the flattened image (i.e., a matrix where each row represents the RGB values of a single pixel)

T and N are some matrices, basically of appropriate dimensions such that the transformation you quoted results in an image of the same shape as the original and also such that we can optimize certain objectives with respect to the variables that define the transformation.

The why this is the desired transformation is a tricky question, it's definitely not the only and quite probably not the best way to formulate this problem - just the first way that I tried and worked reasonably well. I tried to explain my intuition for this in the article after the definition.

comment 5y ago · link · parent

Thanks! The optimal transport is really cool!

comment 5y ago · link · parent

> "Flowers replaced to red" looks like it also tinted the whole sky red.

That's true, to me at least it looks like in the original image the sky has a yellow undertone so I think it makes sense

comment 5y ago · link · parent

Thanks! Yeah, I think one thing the simplistic optimization is missing is preserving the "texture" of the image. There are various numeric ways to represent textures so this is something that potentially could be added to the objective, it was out of scope for the project though. Might give it a try some day!

199.

Image color replacement with numerical optimization(andersource.dev ↗)

78 points · by andersource · 5y ago · 17 comments

comment 5y ago · link · parent

Those are incredible, thank you!

comment 5y ago · link · parent

OT but would you mind sharing some of it? That sounds really interesting.

comment 5y ago · link · parent

That's really nice!

comment 5y ago · link · parent

Not very neatly organized but it's almost all here: https://github.com/andersource/andersource.github.io/blob/ma...

comment 5y ago · link · parent

Hey, what a surprise to see this here!

This came up in a discussion a few weeks ago and there were some interesting suggestions, I'm itching to follow up on the swarm with "boid" behavior one.

205.

Image color replacement with numerical optimization(andersource.dev ↗)

2 points · by andersource · 5y ago · discuss

comment 5y ago · link · parent

Haven't read thoroughly but it seems they are investigating ResNet models [0] trained for image classification.

> We apply CKA to a family of ResNets of varying depths and widths, trained on common benchmark datasets (CIFAR-10, CIFAR-100 and ImageNet)

[0] https://arxiv.org/abs/1512.03385

comment 5y ago · link · parent

I didn't know there was a standard nomenclature for that! Though of course there is :)

And yes, another commenter noted on that, it would make for an interesting addition to the problem.

comment 5y ago · link · parent

Good catch! The technique needs modification to handle uncertainty (i.e. if we don't know which variation of the digit this clock uses), by relaxing the constraints around the uncertain LED segments for the digits with variations. My guess is that the problem will still be constrained enough to be easily solvable again by constraint propagation, but I haven't tested that.

209.

The faulty digital clock problem(andersource.dev ↗)

91 points · by andersource · 5y ago · 16 comments

comment 5y ago · link · parent

That's a great idea!
1
56789