Better HN
topnewbestaskshowjobs
Log inSign up

Lord_Fixer

12 karma · joined Aug 30, 2016 (10y ago) · 21 submissions

Submissions

comment 2y ago · link · parent

A (yet another) strong_typedef implementation for C++.

strong_typedefs allow you to create new types that are derived from existing ones, but are not implicitly convertible to them. This allows you to create types that are semantically different, but have the same underlying representation.

Using strong_typedefs helps in avoiding some common pitfalls, like accidentally adding a distance to a time or passing a weight to a function that expects a price (where all of could be represented by a double).

This (single-header) library also provides a convenient way of defining common operators for your new types. You can express that it makes sense to multiply a price by a quantity, while preventing the multiplication of two prices.

2.

A strong_typedef library with strong operators - C++(github.com ↗)

1 points · by Lord_Fixer · 2y ago · 1 comment

3.

Adding instance-level accessibility mode to C#(github.com ↗)

1 points · by Lord_Fixer · 5y ago · discuss

4.

High performance WinForms grid rendering engine: DynamicGrid(github.com ↗)

1 points · by Lord_Fixer · 5y ago · discuss

comment 7y ago · link · parent

Git repo: https://github.com/TomaszRewak/TimeWriter More info about the project: https://blog.tomasz-rewak.com/text-sourcing/

6.

An online collaborative text editor based on event sourcing(text-sourcing.tomasz-rewak.com ↗)

2 points · by Lord_Fixer · 7y ago · 1 comment

comment 10y ago · link · parent

This website is a part of my engineering thesis. I have started creating it as a private project and just then decided to publish it. It's an online sandbox created for teachers to help them explain students how the computer's memory looks like during program execution. It provides TRE programming language, designes just for this portal. I know that this approach has some disadvantages, as I don't expect people to want to learn it, but I've had some rasons to do it this way. First, I wanted to put inside it as many programming concepts, as possible, which I wouldn't be able to do while using, for example, js. Second, and more important, I just wanted to create my own programming language, to see how it's done and to learn something new myself. To compensate that, I've decided to create series of ready to use programs, so people might just pick one and see how it works, without learnig TRE. Creating those lessons is still in progress, so there are just few available right now. The whole project is just an early version (even tho I have been working on it for a while), so some things might not work as expected, or not work at all. I wanted to share it to collect some feedback, especially that I have released a source code today on the github.

8.

Data structures and algorithms: computer's memory visualization – online sandbox(trepl.xyz ↗)

4 points · by Lord_Fixer · 10y ago · 1 comment

comment 10y ago · link · parent

Yeah, sure, why not :) I will have some spare time at the weekend, so then I will try to implement evenything that has been proposed in the feedback that i've got.

comment 10y ago · link · parent

Yes, I did, but as you mentioned, where's fun in it? :D

When I create projects of my own I like to face some challenges that help me improve my skills. On the other hand there is work, where I use libraries and other ready stuff, as the software has to be usually deployed as fast as possible and in the highest quality. But with project like this I can take my time and just have fun :) And by fun I mean comming up with an arhitecture, code optimization, data structures (like quad tree in this example) implementation and many others.

comment 10y ago · link · parent

It's more like game engine, not a graphics engine. Canvas enabled me to draw basic shapes with a specific transformation. I had to implement something, that would give me a convenient way of managing them (like grouping them, or animating them - as canvas only provides a way of drawing and forgetting them). So with my code I can add an object to some scene, add children to it, transform it at the fly and move the camera. With pure canvas that also would be possible, but not as simple.

comment 10y ago · link · parent

After 100 generations thay actually have learned to move correctly, that's impresive. But they move very slowly. But for 100 nodes in a single hidden layer it takes them only around 10-20 generations to learn for me (not 80), and they race really fast.

comment 10y ago · link · parent

It might be that in the process of learning, algorithm decided, that it can pass a constant value at the speed output and use this one node just to steer.

But I'm testing this scenario right now, and all I can get are cars going on different curves. Are you sure, that you have restarted the process after making changes to the script?

comment 10y ago · link · parent

I might be wrong, but isn't it? I think, that in fact it is, and what you are talking about is reinforcement learning with tabu search, or something.

EDIT: Sorry, I've understood you wrong, what you are describing is, of course, not a tabu search, but still I believe that this GA is a reinforcement learning.

EDIT2: After some research I can say, that opinions are divided :D

comment 10y ago · link · parent

Yes, that's correct.

comment 10y ago · link · parent

Actually when I was designing this, I thought that it will take at least 100 generations to learn some simple moves. But NN are powerful indeed.

comment 10y ago · link · parent

Yeah, that might be true, and that's what this editor is for :D I didn't want to give users the best solution at the beggining, so they might search for it themselves. It's actally only the third combination of parameters that I've tested.

On the other hand 0.5 is not so large, when you look at the mutation procedure. If a speciman is going to be mutated, only 20% of it's weights are changed and only within a range [-0.1,...,0.1]. But fill free to experiment :)

comment 10y ago · link · parent

Thanks for sharing.

You can find here all of the code. Everything here is written (by me) from a scratch, beggining with game engine, and ending on ML algorithms. It's taken to the level where I even multiply matrixes for graphics transformation, operating on pure HTML5 canvas. So everyone should find there something interesting for him. Only editors are a great plugin for ace C9.

comment 10y ago · link · parent

Thanks :)

I actually have had inactivity detection implemented at some point, but I've resigned of this in favor for user-defined stop condition. But you are right, I will bring that back.

It's actually expected that in some cases it might take many generations to learn, as the population is rather small. In other attempts they can do this in like 5 generations, so please, tray to restart the whole process.

Keeping one track untill at least one car is able to finish it is not as good idea as it seems due to ovefritting. The will simply memorize all the moves depending on some insigificant factors and they won't be albe to finish any other track. I have tested that :D

comment 10y ago · link · parent

Thanks :)

Yup, I (as a developer of this thing) haven't created a documentation yet, but it's mostly due to the fact, that I have deployed this just yesterday and there are still many things that I'd like to change in it. But I will work on that :)