Chat:World/2021-02-26

From CG community
Jump to navigation Jump to search

hash101: hello

Default avatar.png JayM9: hi

Default avatar.png JayM9: can someone help

Default avatar.png JayM9: I dont know how

Default avatar.png Tuo: ?

Default avatar.png JayM9: to do this, it says that this man has a square grid with size N * n and I need to find how many 4 square plots are in there

Default avatar.png JayM9: But, the problem I am having is that if it is a 5*5 square, then there will be units in between the groups of squares

Default avatar.png JayM9: swhich cannot be used to account for a square total

Default avatar.png Tuo: you proply have to place the squares in the grid

Default avatar.png Tuo: not just calculate how many there is

Default avatar.png Tuo: or maybe a better formula then just n*n/16 :)

Default avatar.png Tuo: * 4

Default avatar.png Thollang: hi

Imsure1200q: hi

MSmits: hi

Imsure1200q: definitely did not give up in space maze

Imsure1200q: 100%

MSmits: you solved it? Or did you 100% not give up yet

Imsure1200q: i 100 100% did not give up

MSmits: yet

Imsure1200q: yet

MSmits: got it

Imsure1200q: but i was desperate also

Imsure1200q: :)

MSmits: it's a pretty cool puzzle from what I hear, quite challenging

MSmits: one of the hardest we have I think

Imsure1200q: was thinking of like minecraft

Imsure1200q: you can make a similar thing in minecraft

Imsure1200q: and then solve it there

MSmits: mmh ok

MSmits: seems a roundabout way but sure

Astrobytes: what happened to your ray-casting NN solution

Imsure1200q: faile

Imsure1200q: too much memory

Imsure1200q: consup

Astrobytes: I see...

MSmits: raycasting NN?

Imsure1200q: also i actually tried training the nn but c++ wouldnt cooperate so l

MSmits: sounds like something for marslander 3

Imsure1200q: yeah

Astrobytes: This goes back a while MSmits

MSmits: no doubt

Imsure1200q: mid 2020

Imsure1200q: imma fai this challenge

Imsure1200q: just because idk what compound interest is

MSmits: but you will do so spectacularly

Imsure1200q: should i just leave this challengee

Imsure1200q: like idk what compund interesti t

MSmits: I dont know what that is either

MSmits: but you can always do easier puzzles first, while you are tortured by the memory of failure

Imsure1200q: yes

Imsure1200q: a

Imsure1200q: finally

Imsure1200q: first place

Imsure1200q: i am very proud of myself and an

Imsure1200q: m definitely not a give upper

Imsure1200q: how many peepl solv space maze tho, stilll 5?

MSmits: i think you can tell from the puzzle main page cant you?

Imsure1200q: hold on leme check

Imsure1200q: was doing like a challenge earlier

derjack: MSmits in othello do you have exact stable discs number algorithm?

MSmits: I think so yes

derjack: using bitboard tricks eh

MSmits: lemme find it, sec

MSmits: it's not my algo

MSmits: I found it

derjack: from edax?

MSmits: I think so, if thats the giant bot thats public

derjack: alright

derjack: and you use it in your bot?

MSmits: yes

MSmits: doesnt help all that much if i remember correctly

MSmits: but I like that it probably solves faster

derjack: then probably it wont help meh, n-tuples would take care of that mostly

MSmits: probably

MSmits: yeha i do this with the information:

MSmits: http://chat.codingame.com/pastebin/aa2070b1-84f1-46fc-b5ca-4971e96ad0a4

MSmits: so with 33 stable disks you win

MSmits: and i also put it through eval with a param

MSmits: evalScore += (stableCount0 - stableCount1) * STABLE_WEIGHT;

Default avatar.png Alexhasapython: hi

karliso: What is n-tuples?

derjack: patterns

karliso: How are hese n-tuples used in games?

derjack: some patterns are better than others i.e. 2x2 corner showing that is owned by your discs is very beneficial

derjack: https://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.108.5111&rep=rep1&type=pdf

MSmits: karliso, it is a lot like training a NN

MSmits: except you determine the structure

MSmits: instead of lettign the NN discover it

karliso: cool.

karliso: Suppose I have eval with weights, like W1 * ount1 + W2 * count2 .. Would training for weights be like n-tuples?

derjack: yes

MSmits: yeah, just a lot more of them

derjack: i use n-tuples and eval weights for othello

MSmits: i can do the whole ntuples thing pretty easily I think. I just havent found a good way to fit them

MSmits: well i know what i have to learn

MSmits: TD or something

MSmits: havent spent enough time learning about it thoug

derjack: its all about training pipeline. im using more a0 style training than TD

MSmits: whats a0?

derjack: it works for any game as long as you design relevant NN for the game

derjack: alpha zero

MSmits: oh

derjack: but without policy. i train only value

MSmits: did you use some base to work off?

MSmits: or did you come up with everything yourself?

derjack: i havent used any libraries

MSmits: yeah i would prefer the value thing also, policy probably helps, but it seems off

derjack: using the description + my experimentations

MSmits: ahh ok

MSmits: I should definitely learn that before I ever get into real NN

MSmits: seems very useful for fitting params, even if you have only like 8

Imsure1200q: i solve circling in space maze but idk how to even translate that into algo

derjack:

Community success rate: 5% :thinking:

Imsure1200q: if theres 7 billion people

Imsure1200q: 5% = 350 million

Imsure1200q: but theres only 8 people solv

Imsure1200q: 8 / 5% = 160

Imsure1200q: so only 160 people even tried

Imsure1200q: well max is like 175

Imsure1200q: dude i wonder how people achieve O(n) in things that seem impossible like wow

Imsure1200q: im so dumb o

Imsure1200q: i think i use recursive waay too much

Imsure1200q: no wonder it takes so long

Imsure1200q: oh

Imsure1200q: thats good i found heuristic

Imsure1200q: but it will probably take a dumb amount of memory and time ill fail anyway

Imsure1200q: and i found 2 solution to circling yaay :/

Sooran: hello~

Imsure1200q: i

Default avatar.png fkaiky: oi

Default avatar.png fkaiky: algum br

Imsure1200q: really hope i have the right heuristic

Imsure1200q: or else

Imsure1200q: astrobytes will laugh

Astrobytes: My sides are splitting.

Imsure1200q: like youre becoming 1 /2

Astrobytes: "split one's sides" - be convulsed with laughter

Astrobytes: How long do we have the privilege of your presence this time? 1 or 2 weeks?

Imsure1200q: studies show that if you laugh ~at me~ you will die

Default avatar.png Blai8: good to know chief

Imsure1200q: oh for the privilege idk

Imsure1200q: like

Imsure1200q: apparently its my fault that my aunts internet is draining

Imsure1200q: idk though ill just get this heuristic into the code and them boom ill leave disappear into the air

Imsure1200q: although im kinda liking how its going effectively and looking back at how dumb i was for not even thinking of it i might try to solve it now so you cant laugh at me and die

Imsure1200q: :sparkles:

Wontonimo: i was worried of my mortality, but with you reassurance my fears have faded

Imsure1200q: yes

Imsure1200q: because so far

Imsure1200q: it works in 1-7

Imsure1200q: but idk about like 8 - infinity

Imsure1200q: breaking nnews level 8 is giving me nightares you guys might die alswell

Imsure1200q: im sorry

Wontonimo: my soul is prepared to be released from this mortal plane if failure becomes an eventuality

Wontonimo: or something

Imsure1200q: oh good i figured something out

Imsure1200q: :clap:

Wontonimo: nah, laughter seems like a better option now that i think it over

Imsure1200q: i just gifured it out

Imsure1200q: figure

Imsure1200q: d

Wontonimo: oh, what?

Imsure1200q: 2 l8

Imsure1200q: cant die now

Wontonimo: it would have solved so many problems though

Imsure1200q: wy level 8 can solve problems?

Astrobytes: Darn. I was just getting ready to shuffle off this mortal coil...

Imsure1200q: thats good

Imsure1200q: ok onto lefel 9

Imsure1200q: ok

Wontonimo: what's the algo (at a high level, no spoilers) that you are using?

Imsure1200q: like basically each moving tile has like

Imsure1200q: a direction (duh)

Wontonimo: fascinating ;P

Imsure1200q: and you take note of the

Imsure1200q: look ok idk how to explain it

Imsure1200q: like instead of all that raycasting nonsense just like

Imsure1200q: use regexp

Imsure1200q: to find how much a tile can move

Imsure1200q: and then you have to do all that A* stuff or something you take the "bounds" of a tile and see if it can intersect with another tile to be blocked or it can be blocked by another block

Wontonimo: so many times words poorly explain code and the best is just to explain with code (but don't do that plz)

Imsure1200q: i didnt even code it yett

Astrobytes: So you know A* now then.

Imsure1200q: cuz i dont wanna see like 100 errors while im tryna get an idea of how my heuristic should be

Passifi: So in the prefix code puzzle I pass all testcases and all validators except for the 4th one. any suggestions how I can Debug this ? The validators don't really give me feedback so I am a little lost ^^

Wontonimo: validators are not supposed to give you feedback, they are there just to make sure you didn't hardcode the solution

Wontonimo: link ?

Astrobytes: And they should be similar to the testcases - but usually testing some edge case

Passifi: https://www.codingame.com/ide/puzzle/prefix-code

Passifi: yeah I get that but how can I improved my solution if I don't know whats wrong ^^

Wontonimo: welcome to programming

Passifi: On paper and in my mind everthing always works till I test it ;)

Imsure1200q: that is how i am doing my heruistic guys

Wontonimo: Passifi - which test case are you failing?

Passifi: Well none .. I only fail one validator

Wontonimo: which validator are you failing ...

Astrobytes: 4

Passifi: the fourth

Imsure1200q: try like making custom test cases run that boom does it fail or no

Wontonimo: so the 4th on should be very similar to the 4th unit test. Usually that's how the creators do this (but not always). Passifi do you have an idea of how you could generate your own tests?

Wontonimo: (and what lang are you coding in?)

Astrobytes: Look at the name of the 4th test

Passifi: c++ I'll have to think about making my own tests its a topic I have been avoiding so far ^^ but maybe a good excercise

Astrobytes: I can confirm that the validator is extremely similar to the testcase, with the same result

Passifi: hmm okay then I'll play around with that a little bit :) thanks for the input guys :)

Astrobytes: np, good luck!

Wontonimo: so, very often for theses sorts of things, i'll first write the code that creates the test (as per the write up, abracadabra becomes 10010001... )

Wontonimo: Passifi one more thing, if you have your decoder, and you write an encoder, you can in c++ write "assert( decoder(encoder(example)) == example)

Wontonimo: for as many test cases as you like

Passifi: okay thanks wontonimo now back to the drawing board :sunglasses:

Wontonimo: every time i submit my bot it seems to rank lower );

Imsure1200q: see your dying]

Wontonimo: with every heartbeat

Wontonimo: quick fact : you can hold your breath for the rest of your life

Imsure1200q: until you die

Imsure1200q: when its the end of your life you cant hold your breath anymore

Imsure1200q: your drowning in quicksand

Imsure1200q: because level 11 is torturing me

Imsure1200q: im like a voodoo doll you know

Astrobytes: Inanimate and full of pins?

Imsure1200q: yes

Imsure1200q: my biceps are cramping from too much facepalmming

Imsure1200q: well at least the movements arent so memory hogging

Imsure1200q: and ifever there is only one solution during a timeframe i can just delete the rest of the heuristics and go with that on as the origin

Wontonimo: yeah, do that! my life depends on it

Wontonimo: uttt is making me superstitious with its randomness or scoring

Imsure1200q: yess

Imsure1200q: figured it ot

Imsure1200q: finalt

Imsure1200q: ok o 12

Imsure1200q: 13

Imsure1200q: im getting bored now

Imsure1200q: i like

Imsure1200q: using blockstates

Imsure1200q: nice 14

Wontonimo: so, are you making a generic solver or are you kinda coding for each level?

Imsure1200q: geenrtic

Wontonimo: +9000

Wontonimo: :thumbsup_tone1:

Imsure1200q: coding for each level wont bypass validator

Imsure1200q: so sleepy tho

TheDayIsMyEnemy: Can someone help me with Bash?

Wontonimo: https://letmegooglethat.com/?q=bash+programming

TheDayIsMyEnemy: are you retarded?

Wontonimo: seriously though, what do you need help with?

TheDayIsMyEnemy: are you?

BlaiseEbuth: Ok..

darkhorse64: :hammer: ?

TheDayIsMyEnemy: Are you BlaiseEbuth?


BlaiseEbuth: To make it clearer TheDayIsMyEnemy, one more time and it's a ban.

Wontonimo: i think Imsure1200q fell asleep on us ... I need updates on my life expectancy!

jacek: short

Passifi: Hehem for those who helped me short update I had part of my code had cout << "error" instead of cerr << "error" and thats what broke it... I feel quite stupid now ^^

jacek: oO

darkhorse64: errors are seldom smart

Wontonimo: sometimes i solve the mysteries of the universe in 30 seconds, sometimes it takes me 5 hours to see that the reason a line of code isn't working is because i have commented it out

Wontonimo: I've been there all too often Passifi

jacek: or when you timeout because you forgot pragma

darkhorse64: or because you add pragma after includes

Wontonimo: ^^ WHAT? oh man...

Wontonimo: (admits noobness and checks code)

darkhorse64: It took me a while for this one

Wontonimo: looks like i was a lucky c++ noob and just did it correctly by accident

jacek: meh. imagine if not

jacek: youd get 3x speedup by now

Wontonimo: that would be nice

Scarfield: "did it correctly by accident" xD

Scarfield: nice one

jacek: software development in practice

jacek: hows the game, chessfield

Scarfield: starting to get there, messing around with eval a bit more, then go for minmax. still havent implemented promote, castling, 3fold or 50move draw though

Scarfield: just testing the eval on legal moves, no depth

Scarfield: oh and no enpassant yet either

jacek: i still needs castling and en passant

Scarfield: yea castling is annoying :p bitboarding i assume?

jacek: yes. though not very smart

jacek: many things i do on bitboards i'd do in array

Scarfield: what depth do you get?

struct: you need to prune a lot

struct: Ordering moves is also important

jacek: 3 plies

jacek: ordering from TT and killer moves

Scarfield: really i would have thought you would get more, iterative deepening?

jacek: yes

jacek: as i said, my bitboard is dumb

Scarfield: xD

jacek: right now im training nn with jacekmax. nothing serious as i still need to make castling, but its already better than my material eval

Scarfield: nice :muscle:

Scarfield: next week i will delve into the depths of minmax'ing, but already 2k lines to handle the game .O

jacek: per game, most of the time it takes to see if king in check

jacek: and i do it from scratch every time

Scarfield: makes sense, you have to check that for every move, unless you somehow know moving a piece wont affect the king

jacek: thats what im planning

struct: how do you check to see if king is in check jacek?

jacek: or buck it, lets copy paste stockfish

Scarfield: rip discovery checks :p

jacek: struct queen, knights moves from king and pawn attacks

Scarfield: same ^

struct: https://youtu.be/U4ogK0MIzqk?t=475

struct: Not sure if keeping track of attacked cells is better or not, I havent coded a chess engine yet

Scarfield: hmm interesting, i have even seen this video before, just forgot about it

Scarfield: seems to be worth it, at least in early and midgame with many pieces reamaining on the board. I just realised i still see if a king is in check from pieces no longer on the board, but well optimization must wait some mor

Scarfield: e

HunterEhrenfeld: we still talking about that chess game lol

jacek: that chess game? are there any other chess games here

jacek: noice https://www.chessprogramming.org/Chess960_Perft_Results

Scarfield: lol why dont you get depth 4 smh xD

Scarfield: all the cool kids are doing that chess game, join us https://www.codingame.com/ide/puzzle/chess

jacek: in 40ms?

Scarfield: ironic my cek

Scarfield: didnt realise it was this explosive

jacek: as with most expotentials

Scarfield: explonentials

jacek: https://en.wikipedia.org/wiki/Wheat_and_chessboard_problem

struct: something seems of

HunterEhrenfeld: which of these league based challenges should i get into

struct: how can position 956

struct: only have 2 positions at depth 1?

Default avatar.png iigna: hey

Default avatar.png iigna: why my console is not working?

jacek: struct read first sentence

HunterEhrenfeld: sometimes i have to refresh screen

jacek: its few random moves from each position

Default avatar.png iigna: in which browser we have to code?

jacek: any modern one

MSmits: netscape obviously

HunterEhrenfeld: i just use Microsoft Word as my IDE

Default avatar.png iigna: wow

MSmits: good intellisense

MSmits: no spelling errors for you

HunterEhrenfeld: proper capitalization as well

Default avatar.png iigna: EXCEL is the best

AntiSquid: it's better with python

HunterEhrenfeld: im going to be #1 in Clash of Code

AntiSquid: there can be no greater goal in life

HunterEhrenfeld: I just got second place by 1 second. I dont think i can meet my life goals

Default avatar.png deoignition: imagine coding in python

HunterEhrenfeld: quick and simple

Default avatar.png deoignition: dynamic typing is ass

AntiSquid: :thinking: can't imagine the world without python

HunterEhrenfeld: i mean, i agree

MSmits: without python there would just be more brackets

MSmits: :)

MSmits: curly ones

AntiSquid: deoignition do you use java by any chance?

Default avatar.png deoignition: AntiSquid no java is ass

HunterEhrenfeld: java is lit

Default avatar.png deoignition: c# > c++ > python > java

HunterEhrenfeld: where did java hurt you

Default avatar.png deoignition: its just a worse c#

Default avatar.png deoignition: i do have to learn it for my gr 12 cs course next year tho lol

HunterEhrenfeld: lol welp

AntiSquid: was asking because there's usually a pattern people follow: hate python, hate JS, hate anything that's good in life, but like Java

Default avatar.png deoignition: i mean it makes sense, dynamic vs static typing is very polarizing

HunterEhrenfeld: dynamic typing seems fake. but it does make for quick coding lol

AntiSquid: java is below the nadir, python is the zenith

AntiSquid: to follow up on polarization

Default avatar.png GeorgiD: ABCDEF to BADCFE in reverse mode what is it guys?

Wontonimo: swap every other letter

struct: replace(/(.)(.)/g,$2$1)

Wontonimo: ^

Default avatar.png GeorgiD: Oh tnx

Wontonimo: print( "".join(zip(x[1::2],x[::2])) )

AntiSquid: so did you win?

Wontonimo: i like the regex way of doing it. don't use regex much these days and kinda miss it tbh.

Kitkat260: hi

AntiSquid: hi

Kitkat260: hru

AntiSquid: gru ?

Kitkat260: hru means how are you?

AntiSquid: so ?

Kitkat260: how are you feeling

AntiSquid: tense

Kitkat260: not bad

Default avatar.png Haichen: hi

Kitkat260: hi

Kitkat260: hru

AntiSquid: hi

AntiSquid: wtafdykaqia ?

Kitkat260: ummm is anyone in there teens?

AntiSquid: where ?

Kitkat260: here

AntiSquid: you are here

Kitkat260: ik

AntiSquid: and the rest of the chat

Kitkat260: ik

Notgoodatcoding5: Hi

Kitkat260: hello

Notgoodatcoding5: How are you?

Kitkat260: good

Notgoodatcoding5: That's good.

SPDene: sorry to have to tell you Kitkat260, but all the other teens have been exterminated by a Martian death ray :P sorry about that!

Kitkat260: oh

Default avatar.png ErnestEnriquez: I am stumped on Episode 1 Shadows of Knight. Any input? I got it to take the first test case.

Default avatar.png ErnestEnriquez: Just not the second

jacek: you have hints on the left

Wontonimo: jokers on the right

Wontonimo: sooo ...

Wontonimo: because i have a one track mind ... ima gonna ask about mcts solver ...

Wontonimo: anyone have any thoughts about mcts solver finding a loss, and then just seems to give up?

jacek: huh

Wontonimo: i mean, when my solver finds a win, it's 100% ... fantastic. when it finds a loss, it just turtles

jacek: at root level?

Wontonimo: yeah

Wontonimo: oh, haha

Wontonimo: cuz it lost

jacek: if all moves are lost, then its lost

Wontonimo: :rofl:

jacek: unless you have so typo in back propagation

jacek: does it play better?

Wontonimo: i was thinking there was some mistake the opponent could do to lose

Wontonimo: no, it doesn't play better.

jacek: choose the lose with most visits

jacek: bigger chance opponent misses his win

Wontonimo: all benefit seems to be eaten

Wontonimo: yeah, i do choose the loss with most visits, but just by accident. i'll review that section of code now that you mention it, thanks

jacek: how do you handle draws

jacek: you do many things by accident

jacek: do you have children

Wontonimo: yes i do

Wontonimo: you know me well

Kitkat260: hii

Default avatar.png Haichen: hi

Default avatar.png Haichen: hi

Default avatar.png Haichen: :grinning:

Notgoodatcoding5: hi

jacek: :thinking:

firestormninja1: wagwan mandem

Default avatar.png Robinouxxx: bite

Default avatar.png Gandaf: Bite

PatrickMcGinnisII: Wontonimo have you tried weighting scores by depth?

PatrickMcGinnisII: oh you are legend in UTTT, so I'm not telling you anything you don't know

jacek: mhm

PatrickMcGinnisII: jacek?

PatrickMcGinnisII: 6th in uttt, did u do it with mcts?

jacek: i got into top20 with mcts, now its mcts+nn

Stilgart: jacek: i was wondering... how do you generate the data for training your nn ?

MSmits: self play I assume

jacek: 1 method is (chess nnue style): if you already have some bot: generate semi-random self-play games, generate millions positions and label them by the bot + N depth search

jacek: 2 method: each iteration mcts self-play games, record the positions and labels of the root value, then train the NN, then repeat the iteration with the better NN

Stilgart: thanks

kovi: ?3 play through cgbench vs. top

Stilgart: now i can look into this nnue style (2nd method is too hazy for me right now)

Stilgart: kovi: is this really the right way to learn ?

jacek: nope :v

jacek: well the idea of first method is to adjust your eval (0 depth) to better eval (n depth), so your eval is smarter

Stilgart: i would assume that this will lead to overfitting and poor performance against the second half of legend

kovi: it did worked on rebless once https://stakernotes.com/diamond-ranked-ml-for-halite3/

Stilgart: it mght work in arena for some time, sure

Wontonimo: if you can get you NN to predict 1 ply worth of score, then you need 2x to 9x less rollouts. If your NN is as strong as 2 ply, then you need (x2 to 9x)^2 less rollouts.

MSmits: except you may get 30 times less rollouts from how heavy it is

Wontonimo: the question is, can you code an NN that costs less rollouts than it is strong.

Wontonimo: yeah, that

MSmits: I think the benefit of NN is most obvious for games where it is hard to even get started with an evaluation

jacek: so far my NN can

MSmits: where the gamestate is quite complex

Wontonimo: some papers say, use the grandfather heuristic and only apply the nn (or other factor) ever 3rd ply to save compute

jacek: but the way i use inputs for the nn, each move needs only to partially update the nn, so its quite fast

Wontonimo: !! cool ^^

MSmits: you mean like incremental eval in a minimax?

MSmits: I used this in my yavalath minimax, when i make a move i only update the part of the eval that deals with that hex

jacek: yeah. this is main idea of nnue. in uttt i use 81 squares as input. at most only few of them are changed

MSmits: ah right

jacek: i have 77760 weights for uttt. each weight takes utf16 char, so almost no little room for more

MSmits: are you sure you need that many?

jacek: i experiment with different net architecture, so far this one is best

MSmits: ah ok

jacek: i have overparametrized inputs, yeah. but it works

MSmits: what are overparametrized inputs?

MSmits: also damn you for making me type overparametrized

MSmits: again!

jacek: its rather vague term. i.e. in uttt each square can have 30 different types, and there are 81 of them. i use one-hot inputs, so there are always 81 ones, out of possible 2430

MSmits: 30 types?

jacek: if i used convnet or something, probably i could get away with less weights, but im too dumb for them yet

MSmits: empty, cross, circle, times 9 ?

MSmits: that's 27?

jacek: square, as tiny square

MSmits: yeah

MSmits: why 30 though


jacek: empty, O, X. +3 if its from active board. +6 if current player is O. + some other i.e. if this square would win board for one side, etc.

MSmits: oh ok

MSmits: so you put in some domain knowledge there

jacek: yeah

jacek: i treat O differently depending whose side to move now, and/or it is from active board

MSmits: good. i think it would make NN's on CG a lot better to have domain knowledge in there. It's all well and nice to try and do an azero and learn from nothing, but you work with limitations

jacek: the training pipeline would take care of the rest

jacek: i put some domain knowledge in bt as well. its not only empty, white black. but also if the square is attacked by one side, by other side etc.

MSmits: ah right

jacek: so protected pawn is different than alone pawn. also technically i have different set of inputs for side to move

jacek: it doubles the weights, but it is much better than just using another input for current player

MSmits: right

jacek: its like thinking of good eval. but you need to think how to make it nn-friendly

MSmits: well the hard part of getting a good eval is not really thinking of the features, it's finding the parameter values

MSmits: it's the other way around for a nn

MSmits: at least that's my experience

MSmits: though in BT it is different, i could not get the right features there

jacek: nowadays we have many ways to optimize them

MSmits: well not me, but sure, science does

jacek: you are not science?

MSmits: not this part of science :)

MSmits: maybe some day

tibithegreat: jacek why not add some other one-hot inputs with the active board and current player

tibithegreat: I think I revived some old discussion, I just entered and saw the discussion and I was curios

jacek: its faster and better to have entirely different inputs based on current player than adding this input. at least in my case. if you do the latter, it would require much more hidden units/layers to see that different current player changes things

jacek: and the way i doubled the input weights, it costs almost nothing, maybe except some cache penalty. but this way i can get away with fewer hidden units so the computation is less expensive

Default avatar.png JayM9: hi guys

tibithegreat: hmm interesting, now that you mention it would indeed make it easier for the NN to make sense of the input

jacek: my approach deals with blitzkrieg naturally

jacek: no, not blitzkrieg. that other german word...

jacek: zugzwang!

jacek: my inputs are prepared so they would be easier for the NN to figure out stuff. i maybe losing generality here, but i dont care

tibithegreat: fair enough

Default avatar.png Haichen: 0k

DragonMaster86: hi

DragonMaster86: :sweat:

jacek: good evening

iso9999: good evening


AntiSquid: yes

jacek: AutomatonNN who is Automaton2000

AutomatonNN: why do you think it was a real one

Automaton2000: you know, the more you know

Default avatar.png SvilenHristov: hey guys, anyone up for little help with on of the coding games

jacek: hm?

AntiSquid: SvilenHristov you can pretty much rephrase that to "can i ask a question"

Default avatar.png SvilenHristov: Can you use Math.min to get the closest distance ?

AntiSquid: i can

Default avatar.png SvilenHristov: this is the code game https://www.codingame.com/ide/puzzle/defibrillators

Default avatar.png SvilenHristov: and my code https://pastebin.com/YYxLWRJz

Default avatar.png SvilenHristov: I think that I calculated all the distances correctly and put them into array, and after that with Math.min I'm finding the lowest value in the array

Default avatar.png SvilenHristov: but the answer is wrong and I stuck at it for too long... :/

AntiSquid: use debug to check at what point you make the mistake

Default avatar.png SvilenHristov: 279379.5538197978, 278940.46901834826, 279560.0406074397

Default avatar.png SvilenHristov: from my side i think 278940 is lower than 279379 but actually is not

Default avatar.png SvilenHristov: so I'm not sure how to compare those 3 values

AntiSquid: you're missing some semicolons at the top

Default avatar.png SvilenHristov: this is javascript the semicolons are not required

AntiSquid: it's late, can't think clearly, but all i can think of are your missing semicolons

AntiSquid: why is everything a const? this is so triggering

Default avatar.png SvilenHristov: const is used for something that will not change constantly

AntiSquid: i think it's your data length -1 -2

AntiSquid: yup it is

AntiSquid: http://chat.codingame.com/pastebin/219ca383-cbe7-4043-a7ec-c258892cb597

AntiSquid: here

AntiSquid: fixed all mistakes

AntiSquid: and you're welcome

Default avatar.png pgroke: Hi, is there a way to opt-out of "shortest code" contests? I'm using C++ and that's not really suitable for writing super-short code...

therealbeef: nope. but it's a good moment to learn another language like python

Default avatar.png pgroke: no, it's not :)

therealbeef: why not?

AntiSquid: those aren't contests, just quick puzzles

AntiSquid: and python is always good to know

Default avatar.png pgroke: because IMO python is a terrible language. as is JS.

AntiSquid: check where python is used, how, how much and mostly who uses python

Default avatar.png pgroke: I could do that, but what would it tell me?

AntiSquid: that your opinion is wrong to put it politely

therealbeef: python and C/C++ interface quite well. so if you're using C++ for work there is a decent chance you'll need to write some python at some point

Default avatar.png pgroke: I've been programming in C, C++ and C# for over 20 years now and I have never used python. And I don't see where I should have.

Default avatar.png pgroke: Re. where it's used/by whom/for what: that's an argument by popularity/authority, both of which are fallacies.

AntiSquid: 20 years of coding and you call clash of code a contest

AntiSquid: python is good as a "glue" at least

AntiSquid: easy fast scripting, pipeline your stuff ...

Default avatar.png pgroke: That may be true. Re. the word "contest" - doesn't the website itself call each puzzle a contest?

AntiSquid: no

Default avatar.png pgroke: Ah, my mistake.

Default avatar.png SkyViper208: Hey, can someone tell me why "&&" isn't working in my if statement? Am I missing something? (Java)

Default avatar.png pgroke: I've read the word contest on the website in another context and ... misplaced it in my mind :)

Default avatar.png pgroke: @SkyViper208 - I'm new to this website, if you can tell be where/how to see your code I could have a look.

Imsure1200q: no way

Imsure1200q: clash of code aint putting me in first place

Default avatar.png SkyViper208: @pgroke I'm new too lol, i

AntiSquid: hey, i don't know what your job involves, but i find it hard to believe you wouldn't benefit from using python

Default avatar.png SkyViper208: @pgroke

Default avatar.png SkyViper208: @pgroke if(nextCheckpointDist > 10000 && boost = 0){

Default avatar.png pgroke: single = is an assignment

Default avatar.png pgroke: not a test

Default avatar.png SkyViper208: ohhh okay thanks

Default avatar.png SkyViper208: two =?

Default avatar.png pgroke: yup

Default avatar.png SkyViper208: Thanks! it worked!

Default avatar.png pgroke: @AntiSquid in my previous job I was developing simple games and after that a Windows embedded video jukebox. In my current job I'm working on the core libraries for an application performance monitoring product that's written in C++.

Default avatar.png pgroke: We use some of the "suitable for glue" languages in our build and automates tests, but those are managed by other teams.

Default avatar.png pgroke: Er. Meant to say: Windows embedded _based_ video jukebox.

Default avatar.png pgroke: (And, well, not the whole APM product is written in C++. But the "agent" is, which is the part I'm working on.)

AntiSquid: cool stuff

Default avatar.png pgroke: https://www.dynatrace.com/

AntiSquid: so what do they use for those charts /geocharts?

Default avatar.png pgroke: Also I should have probably said it's a "software intelligence solution", because it does much more than APM. But people tend to not know what "software intelligence solution" means - whereas many at least have a vague idea when I describe it as application performance monitoring. Which after all is a bit part.

Default avatar.png pgroke: Frankly I have no idea what the UI side does/uses :)

Default avatar.png pgroke: That's so far away from the code I'm writing. It's a big product.

AntiSquid: was just curious, not implying it has to be python, but it's definitely easier in python than c++

Default avatar.png pgroke: what is?

AntiSquid: charting

Default avatar.png pgroke: Ah.

Default avatar.png pgroke: Well, the server side is in Java and the UI stuff obviously partly in TypeScript (client side).

Default avatar.png pgroke: The part I'm working on is the agent. The agent runs on servers of our clients and monitors their applications. You want performance there and you can't use anything that uses a runtime which you cannot tightly control. And performance not only means running fast but also starting up fast.

Default avatar.png pgroke: So basically anything that doesn't compile to native code is automatically out.

AntiSquid: D3 i am guessing then (geochart vis)

Default avatar.png pgroke: Possible, as I said, no idea.

AntiSquid: well you monior the software, gather the data and store it, no?

Default avatar.png pgroke: More of less. But only parts of that are done in the agent obviously.

AntiSquid: all that analysis is usually done in something "easier to approach" for common folk

Default avatar.png pgroke: At some point the agent sends the data to a cluster which analyzes it etc.

Default avatar.png pgroke: Sure.

AntiSquid: ya see this is where python shines, since there are a lot of tools readily available for this kind of work, but maybe your company uses something else ...

Default avatar.png pgroke: I know. In that regard, Python is like Playmobil. There's a lot of fancy stuff readily available, but if there's no library that does what you want, and you can't build it by combining some libraries then you're pretty much f-ed because you can't write the actual data processing in Python. I mean of course you can, but then the performance will be so bad that it's unusable.

Default avatar.png pgroke: And I'm more of a Lego Technics kind of guy :)

Default avatar.png pgroke: But that's not my main problem with Python. My main problem is that it doesn't have static typing and it allows you to modify the structure of existing objects. (BTW: is that still possible using the "new" class model?)

Default avatar.png Migecha: I kept on pressing ctrl + s :(

therealbeef: weakly typed languages like python or ruby are ok if you got your unit tests in order, but as a C++ programmer it still creeps me out ;-)

AndreMarasca: 11 days until SPRING CHALLENGE 2021 :)

therealbeef: wait what?

therealbeef: isn't it in May?

Default avatar.png pgroke: try refactoring stuff in a weakly typed language. it's a nightmare - with or without unit tests.

MadKnight: what? the spring challenge is already so close?

MadKnight: but i'm not ready

Lobster_Speed: spring chall ge

Lobster_Speed: what is that

Lobster_Speed: I only do clash of code on this site


therealbeef: the main page says 11 days, but also says May 6

therealbeef: https://www.codingame.com/contests/spring-challenge-2021

MadKnight: lol

MadKnight: ooooh dammit 11 days is the length

MadKnight: AndreMarasca cmon

therealbeef: :sweat_smile:

MadKnight: therealbeef were u trolling or u also thought 11 ?

therealbeef: also thought 11

MadKnight: but it usually shows the time left until the event in a big fancy timer

Kitkat260: hi

therealbeef: yeah

Kitkat260: hru

MadKnight: wb kitkat

MadKnight: therealbeef are u getting ready for the contest ?

therealbeef: sure, previous contest was my first one, but i only joined halfway. want to see how far i can make it :)

therealbeef: trying out some algorithms in the meantime

MadKnight: oh, and on what games ?

therealbeef: uttt, and now csb

MadKnight: what algos ?

therealbeef: minimax, mcts

therealbeef: and trying some gradient descent on csb

therealbeef: wish i understood QCQP

MadKnight: is gradient something like SA ?

therealbeef: what is SA?

MadKnight: or what's the general idea ?

MadKnight: SA is like full random move generation + mutationm

therealbeef: ah, like genetic algorithm?

MadKnight: like that, but no crossover

therealbeef: gradient descent is when you make a score function that is differentiable, and then compute the gradient and make steps upwards toward local optimum

MadKnight: and mutations are very big in the beginning but they decrease over time

therealbeef: simmulated annealing?

MadKnight: oh, SA does that exact thing with random mutations that derease over time

therealbeef: sounds like annealing

MadKnight: yea

MadKnight: so what are u searching with that thing in csb ?

therealbeef: well, the function for the pos position at time t is linear, so the distance to the next checkpoint is quadratic. then there are constraints that are also quadratic

therealbeef: *pod

therealbeef: so it's quadratic constaint quadratic programming

therealbeef: not easy to solve

therealbeef: apparently i should rewrite it to something called semi-definite programming and use an interior point solver, but i lost it there ;-)

MadKnight: wait are u not in gold yet

MadKnight: what league are u in ?

Default avatar.png TaykYoku: hi

MadKnight: iih

therealbeef: gold

therealbeef: i know many people do neural networks or genetic algo but those should always be beatable by a domain specific algo

Default avatar.png pgroke: test

therealbeef: ...ok...

Default avatar.png pgroke: the chat stopped updating for me. no idea why.

MadKnight: therealbeef

MadKnight: still there ?

Default avatar.png mingmingrr: is there a setting to share code by default?

Default avatar.png Binary_Sky: there is one but i still get option to share

Default avatar.png Binary_Sky: tell me if mines will autmaticly share, i have it on

Default avatar.png mingmingrr: yup, yours auto-shares

Default avatar.png Binary_Sky: yours also shared, unless if you did manually

Default avatar.png mingmingrr: i did it manually, do you know where the setting is?

Default avatar.png pgroke: click your username->settings->scroll down

Default avatar.png danielkim9999: join our twitch stream and play with us :) twitch.tv/learnwdaniel