#programming

1 messages · Page 205 of 1

obsidian mantle
#

I thought you said you want to check that manually

real sierra
#

whats sbt

tender river
#

to build a jar do sbt assembly

tender river
real sierra
obsidian mantle
#

Can it just output max length string with token counter so you see it right away

real sierra
#

can i just apt install it

tender river
#

maybe neuroThink

real sierra
#

nope

#

half of my storage on this vm is build tools

balmy nacelle
#

i decided to throw random values in until it feels nice

tender river
# real sierra half of my storage on this vm is build tools
echo "deb https://repo.scala-sbt.org/scalasbt/debian all main" | sudo tee /etc/apt/sources.list.d/sbt.list
echo "deb https://repo.scala-sbt.org/scalasbt/debian /" | sudo tee /etc/apt/sources.list.d/sbt_old.list
curl -sL "https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x2EE0EA64E40A89B84B2DF73499E82A75642AC823" | sudo tee /etc/apt/trusted.gpg.d/sbt.asc
sudo apt-get update
sudo apt-get install sbt
#

ip grabber

real sierra
#

holy ip grabber

#

but alas i dont have deb either

tender river
#

i just use nix where its packaged evilNYA

tender river
real sierra
#

no yum Tomfoolery

#

ubuntu fork

tender river
#

neuroCatUuh why wouldnt it have apt-get

real sierra
#

it does have apt get

real sierra
#

doesnt have deb

tender river
#

what do you even mean by that

real sierra
#

am i reading this wrong

tender river
#

yes colonthree

real sierra
#

oh right

#

my java is just sitting in a folder

#

i dont actually know how to make it globally callable

tender river
#

easiest way is adding export PATH="$PATH:/opt/java/bin"

#

to ~/.bashrc

real sierra
#

still doesnt work

#

do i need to reload it or something

tender river
#

restart shell

fast pagoda
#

source ~/.bashrc

#

assuming ur in bash shell

real sierra
#

ty

quiet mirage
fast pagoda
#

yeah im something of a leet hax0r myself (i fuck with my ~/.zshrc and reload it constantly)

tender river
#

every morning i go to sleep

real sierra
tender river
fast pagoda
#

every morning i break my legs

#

every afternoon i break my arms

#

at night, i lie awake in agony until the heart attacks put me to sleep

tender river
#

hi t neuroWaveA

stray dragon
#

how

#

hi chayleaf

tender river
fast pagoda
#

chay audits all reactions

real sierra
#

right

#

now that i have the new token counter

#

lemme see if theres anything else i need to do before contest open

#

i need to add the rust api docs

tender river
#

haskell bindings neuroMad

real sierra
#

wait

#

i was supposed to write those?

tender river
#

me

real sierra
#

o

tender river
#

but you made me write token counter

#

it's all your fault shiro

real sierra
#

you're the only one waiting on them so i can start contest without surely

tender river
real sierra
#

just like scrub hasnt submitted the C# bindings yet

tender river
obsidian mantle
tender river
fast pagoda
real sierra
#

i mean

#

i kinda chose a month timeline to be more than enough time

#

i think people will spend far less time on the contest than a month

fast pagoda
#

when was this decided

tender river
#

some people took multiple months on sebastian lague's contest evilShrug

real sierra
#

well if the haskell bindings wont take long

tender river
#

my point is i don't feel the need to rush it

real sierra
#

sure but

#

there will guaranteed be requests for new languages after the contest starts either way

#

no matter how long i push it back

#

some people just wont hear about the contest until it starts, and then request something

#

so idk how much delaying it really helps

tender river
#

it helps me evilNYA

real sierra
#

neurOMEGALUL i know that

obsidian mantle
#

Announce it and give people couple of days to submit languages they want PauseSama
Give away api after that and start 1month countdown

tender river
#

it wont help those who dont know about it yet so but that cant be helped

tender river
#

you have to have the api to create language bindings

obsidian mantle
#

Oh they are supposed to make it themselves

#

I thought you volunteered to make all of that

#

For some reason

silent cloak
real sierra
#

nono lol

#

i made the C and python bindings

#

but i dont know rust or haskell or C#

#

so i obviously cant make bindings for those

obsidian mantle
#

How does it even work
Dont you just need a list of pointers for every function and that's it?
This sounds like 5 min problem

tender river
silent cloak
#

U don't know C#?

real sierra
#

i thought about it for a min

silent cloak
#

Ask Byter for rust neuroTroll

real sierra
#

and i did already agree to give you the repo ahead of time for the purpose of making haskell bindings

#

so i guess its only fair

#

but also if anyone asks for a timeline on the contest starting, im pointing them at you

tender river
silent cloak
#

The one Haskell user left using the bindings

real sierra
#

i dont think it'll take you long

obsidian mantle
#

PauseSama when does it start

real sierra
#

i made the python bindings quickly and im terrible at this stuff

silent cloak
#

Is this a neuro contest

tender river
real sierra
silent cloak
#

Whats the goal

real sierra
#

@trim valve do you have the rust api hosted somewhere?

#

would like to link it

obsidian mantle
#

Evil, do the announcement

real sierra
silent cloak
#

Interesting

real sierra
#

my submission is currently 1050 tokens pepeS

#

need shrink

silent cloak
#

Idk if minifiers exist for C

real sierra
#

minifiers wont help with token count

#

thats the point of using token count instead of just length or char count

silent cloak
#

Sounds like a cool challenge

real sierra
#

its tricky

silent cloak
#

Im still working on my anti chess bot idea

real sierra
#

trying to compress so much logic into a tiny space

silent cloak
#

Im doing university work atm

tender river
#

erf
i checked antlr/grammars-v4, and the only useful languages to add would be:

  • swift
  • smalltalk
  • scala
  • java
  • any lisp
  • prolog (questionable choice)
  • pascal
  • objective c
  • lua
  • kotlin
  • javascript
  • java
  • go
  • fortran
  • erlang
  • elixir
  • cobol
  • ada

other ones would have to have a custom tokenizer impl (not that hard but more effort than usual)

real sierra
#

ive been trying to figure out if theres a library in C that imports stdlib and stdbool so i can eliminate one of the imports

real sierra
#

if it were supported they'd be on board to participate i think

tender river
#

you can use _Bool tho

#

(deprecated in c23)

real sierra
#

i'm compiling these with c23

silent cloak
tender river
real sierra
#

literally almost everything is macros

#

i dont know what to do anymore

silent cloak
#

Is it open source

real sierra
#

my bot? no

#

the chess api the contest sits on top of? it will be once the contest opens

silent cloak
#

U can always see how ur compiler handles code changes and just manually implement them

real sierra
#

wouldnt that make my code bigger

silent cloak
#

If the compiler changes something to be smaller then implement it yourself

real sierra
#

the token counter runs on the source code, not compiled code

real sierra
tender river
#

i have 2 projects i've committed to for other people, 2 phd-level projects i'm dedicated to myself and associated reading, manga scanlation project, aaaaaaaaa how do i get time (don't say use discord less)

silent cloak
#

It does at times

#

Especially with branching

real sierra
#

i never made any guarantees YES

#

up to your availability is fine

tender river
real sierra
silent cloak
#

Tbh when it comes to algorithms psudeocode is actually useful for taking a step back and trying to optimize

real sierra
#

so is it the haskell bindings worrying you

tender river
#

mhm and other stuff

real sierra
#

or do you think you wont be able to write a bot even if you make the bindings

tender river
#

evilShrug i'll see what i can do

#

a month is a long time

silent cloak
#

Damn that's a while

real sierra
#

yeah i mean

#

my bot is only 250 ish lines right now

#

50 of which are defines and structs

#

it doesnt take long to get that much code down

#

but i respect you're a busy person YES

silent cloak
#

I think u should look at the optimization steps used in some compilers to see if there is anything u can use as reference

real sierra
#

i dont think there is

#

i dont need machine code

#

it needs to still be C

#

ive already looked at the compiler builtins to eliminate libraries

#

and i dont think much of this can be inlined with a reduction of tokens

silent cloak
#

I mean how it handles eliminating parts of the code

tender river
#

you put too much faith in compilers Neurorb

silent cloak
#

You put too little

tender river
#

i literally write them

silent cloak
#

Yeah but good ones

tender river
#

sorry i don't take compiler opinions from c# devs

real sierra
#

MONKA war

silent cloak
#

I work in more than just C#

tender river
#

like c# = c# dev

#

simple as

silent cloak
#

Idk pal if u can write a better compiler than the existing ones u can be really rich

tender river
#

you really cant

#

theres not much money in compiler writing

#

most compilers are written by a single person for a single person

#

and people routinely make better compilers for specific tasks through specialization

silent cloak
#

Well duh because at that point they might as well be writing asm for such cases

tender river
#

nope colonthree

silent cloak
#

Me writing a compiler to compile a single program

#

Rust mindset

tender river
#

thats something i do quite often

silent cloak
#

Dodging asm like rain drops

real sierra
#

1048 tokens

obsidian mantle
#

But if everything is macros
Shouldnt you optimise the macros

real sierra
#

i am

#

i have macros of macros

#

ive looked through to see if any were bad but no

#

they all gain tokens

#

and they're all in use somewhere

tender river
#

roslyn's great evilNodders

real sierra
#

dont know what shrink

#

maybe need make bot worse

obsidian mantle
#

Because of 24 tokens neuroD

real sierra
#

because of 24 tokens

#

i could simplify the material eval function

#

that might save tokens

#

i wonder what the unmacro'd size of this is

#

is there any way to run the preprocessor macros

faint sandal
silent cloak
faint sandal
#

they LOOKED UP THEIR IRL NAMES

real sierra
#

1042 tokens

#

i really dont know how to shrink this further

#

#define cbclose_return_rv_sc_cbclose_void } return_rv_sc } void

obsidian mantle
#

It must have something big

real sierra
#

we're getting REALLY interesting now

#

neurOMEGALUL it works

#

1037 tokens

#

13 more

#

but how...

fast pagoda
#

just start deleting lines and see if it still compiles/works

#

blindfolded

obsidian mantle
#

Really hard to guess what can be shrunk when you dont see the code
It sounds exciting cant wait to start

fast pagoda
#

set up a python referee for legal moves and now have a working shitty chess """"api"""" to test games

#

both the test bot and my actual bot are currently rng lords

#

made stockfish analyze the rng games

#

he's on the edge of his seat for the last 100 moves of this 200 move game of just nothing happening while white randomly runs around

#

he did in fact have 3 fingies but at first i thought the ai was just being savage as fuk looking at this game of his

#

like damn i know he lost but you dont need to go that far

obsidian mantle
fast pagoda
#

paranoid, decide to check if the stupid shai halud thing got into any packages ive built with any other node crap i was building

#

500+ packages are on the list

#

jesus christ

olive sable
#

shiro did you watch the new dr stone episode?

rigid snow
#

bun:ffi exists, maybe just not use node then?

import { dlopen, FFIType, suffix } from "bun:ffi";
const { i32 } = FFIType;

const path = `libadd.${suffix}`;

const lib = dlopen(path, {
  add: {
    args: [i32, i32],
    returns: i32,
  },
});

console.log(lib.symbols.add(1, 2));

like this is so much nicer than writing miles of v8 fuckery in cpp

#

claims to be way faster too

trim valve
rigid snow
trim valve
#

tl;dr gonna try and see if I can make zercopy play nicely with my structs

rigid snow
#

or at least i think it was allowed

nocturne olive
#

Still no Kotlin token counter I assume

hollow spruce
#

Token limit

trim valve
#

I think we're a bit closer to it now?

hollow spruce
#

Every new day every Chrome bugs update

trim valve
nocturne olive
#

It would be cool

#

Otherwise I can't really chess bot with any reasonable amount of effort for such silliness

trim valve
rigid snow
#

right that's what i thought

#

libuv does async io by polling

#

i mean epoll specifically, not blocking

#

file io is a thread pool still

obsidian mantle
#

How does it work
If you are using one thread, whats the point of multithreading?

#

Oh i mean if you are using one core

#

Why would we interrupt whatever is happening in its head

#

Its alright when we have some interface which gives commands in random times, but here we have "wakeup -> receive go command -> make decision -> return decision -> sleep"

rigid snow
#

yeah as far as i understand getting the board or something else is blocking until your move

#

no way to make a blocking function nonblocking without offloading to a separate thread

#

and any threads are off-limits

obsidian mantle
#

Its supposed to freeze the bot out of your turn
And when turn starts you already received a command to go so you are not waiting for any input

#

At least shiro said its not allowed to think when it isnt your turn
Because tournaments go like that

rigid snow
#

right then it's not an issue

#

but still doing node bindings is probably a good idea?

obsidian mantle
#

I dont know what that is neuroCry

rigid snow
#

node js

obsidian mantle
#

Oh

opaque sigil
#

node bindings are a pita, just throw bun ffi at it

obsidian mantle
#

I dont know it anyway ICANT

silent cloak
#

brainfuck bindings

rigid snow
#

semicolon would approve

stark needle
#

my interviewer for the company i don't want but have to interview for just left the room for a personal call and was like "please don't disconnect it's not like i'm not coming back"😭

rigid snow
#

is this right now

stark needle
#

yes

rigid snow
#

go back to your interview

stark needle
#

it's on teams

#

bros still not back

opaque sigil
#

things happen

scarlet arch
stark needle
scarlet arch
clear sedge
clear sedge
obsidian mantle
#

If you learn anything in the process it might be worth

scarlet arch
clear sedge
obsidian mantle
#

Then you must enjoy it

#

Whats your motivation otherwise

clear sedge
#

i am merely doing this because i don't want a billion dependencies

obsidian mantle
#

Seee

#

Useful!

#

Not a waste if there is good reason

clear sedge
#

then i'll be using my json parser for a gltf parser

stark needle
#

wasn't json.h a single header

rigid snow
#

having a dependency you can upgrade? nah, you'll write your own that's worse and maintain that yourself

obsidian mantle
clear sedge
#

dependencies are for pussies

#

except sdl

#

i don't wanna deal with window management

silent cloak
#

write it in a dead language that someone has to pay a lot to get forked in a decade

clear sedge
#

or opengl context creation

stark needle
#

shiro chess bot mindset

silent cloak
#

my mother knows it somehow still

clear sedge
#

yo momma so old she still knows cobol

silent cloak
#

she doesnt look a day over extinct

hollow spruce
#

Compute unit is ending "hell no

#

I need buy again

warped narwhal
amber fractal
#

bwa

#

today seems to be working on more NN stuff. Probably continuing to build out the test suite for the latest two modules.

#

If I ever want to try my hand at the chess bot tournament I do need this to work.

hidden ravine
#

@true hemlock bro fix wifi pls

amber fractal
#

neurOMEGALUL the bot is demanding it's owner

#

One day QuackFM one day

sage crag
nocturne olive
#

SoSilly

amber fractal
hollow spruce
#

Bot + user 🤣

rigid snow
#

🤣

amber fractal
#

If we had a bot account we'd never get funny moments like this

rigid snow
#

why not

hollow spruce
#

Self bot will get caught

rigid snow
#

discord tos so scary

#

i am shakinmg and quiveriung

hollow spruce
#

My one account will screwed up

#

Chrome patch cvs patch

amber fractal
#

It's been awhile. Time to see if discord py is as bad as I remember.

#

I still hear complaints from time to time but need to see that for myself.

opaque sigil
#

the api hasn't really changed at all but it's actually somewhat maintained again

#

not like a couple years ago where it was basically on life support for a while

amber fractal
#

Yeah, I swapped off to another library and just never looked back.

#

Honestly, still don't have much reason to

opaque sigil
#

same, rewrote it in typescript and now i'm chilling

#

though i'll never not get annoyed at the inheritance monstrosity that is discord.js when i need to look at it

amber fractal
#

moved to something a bit more sensible

#

Despite not using discord.py, having functional docs with a lot of normally extensions bundled in is nice. I don't use the native hotloading as much as I should be tbh.

opaque sigil
real sierra
#

good morning

#

holy I was up late

hollow spruce
nocturne olive
#

So somehow Discord was takiing up 15GB of my memory

opaque sigil
#

impressive enub

clear sedge
nocturne olive
clear sedge
#

if i had to guess, someone fucked up with some voice call handling logic or web socket bs

#

¯_(ツ)_/¯

hollow spruce
#

Model2.py :

import random

arr = None

try:
import torch
arr = torch.rand(9)
print("Using torch:", arr)

except ImportError:
try:
import numpy as np
arr = np.random.rand(9)
print("Using numpy:", arr)

except ImportError:
    arr = [random.random() for _ in range(9)]
    print("Using pure Python:", arr)
#

Im lazy i don't need
Import Numpy every change so
I make fall back script that it change depending on model

sage crag
#

this seems useless

clear sedge
#

using import errors that way...

#

is there no better way to check if a package exists??

hollow spruce
#

ModuleNotFoundError: No module named 'model2.py'; 'model2' is not a package

#

I forgot again' make package

midnight sigil
#

also you don't import py files with import name.py

#

you just do import name

#

or import .name, depending on your environment

midnight sigil
#

if my client is so dumb that he/she/they can't see the fucking requirements.txt, I'm not letting them run my scripts

hollow spruce
#

My script is working that fine

midnight sigil
olive sable
hollow spruce
#

I will added more tools in (model2.py) in such as tension flow etc packages

rigid snow
#

good work apple, i airdrop a file to my phone and it disappears. shows as finished but nowhere to be found

opaque sigil
rigid snow
#

nice software

opaque sigil
#

Nice

river copper
#

Hey can one of you that are good at programming and scripting AI stuff message me?

hollow spruce
#

F my earphones are not use able

#

Well I deleted again my .venv

clear sedge
#

impostor!

opaque sigil
hollow spruce
#

My pc crash again

real sierra
#

mint Chatting

rigid snow
# sage crag this seems useless
import importlib
try:
    importlib.import_module('torch')
except ImportError:
    import pip
    pip._internal.main(['install', 'torch'])
finally:
    globals()['torch'] = importlib.import_module('torch')

arr = torch.rand(9)
print("Using torch:", arr)
#

is this more useful

sage crag
real sierra
#

konii

#

can I change channel on your tv

sage crag
real sierra
#

wait actually what are the specs of the tv

sage crag
#

480p 1hz

real sierra
#

1hz

rigid snow
#

are you overclockable

olive sable
#

coffee

real sierra
#

sam

#

do you think konii is simd

#

I think konii would make an excellent edge computing node

#

we should write some benchmarks

trim valve
#

can I submit konii as my chess bot

real sierra
#

if konii was somehow at my computer then that wouldn't break any rules I guess

#

agh it's too late to be worth going to class

#

I've missed 25% already

olive sable
real sierra
#

hey question

#

how often can I get unexplained chest pains before I should worry

opaque sigil
#

My rule of thumb is if it happens more than a handful of times a week there's probably something wrong enub

noble zodiac
#

however often your doctor said its ok

dapper kernel
real sierra
#

my brain filters it out at this point

#

no more surprising an occurrence than the sky being blue

dapper kernel
#

You should see a doctor

real sierra
#

I should see a doctor

dapper kernel
#

Yes you should

real sierra
#

I went recently and they just never sent me the results

dapper kernel
real sierra
#

lmao good luck contacting the doctor here

#

it was only due to seeing the nurse's surprised reaction at my blood pressure that I decided to test that myself

#

my blood pressure is about as high as you can be and still be safe, but my pulse is as low as you can be and still be safe

#

not really sure what that entails

dapper kernel
#

That doesn’t sound healthy neuroLookUp

real sierra
#

I'm kinda inclined to agree

dapper kernel
#

(If u went on reddit u might have an answer)

dapper kernel
#

Take care of yourself

real sierra
#

you would catch me dead before getting medical advice from Reddit

#

actually

#

you would catch me dead shortly after getting medical advice from Reddit

dapper kernel
dapper kernel
rigid snow
#

this is creepy

#

i got chest pain around the time you sent that

real sierra
#

spell of chest pain

uneven pulsar
#

anyone else about to do a win11 clean install to avoid the pain of some update that's totally gonna break

real sierra
#

nah

#

not worth the effort

uneven pulsar
#

i hope the 9/2 sophia script is ready

real sierra
#

if it breaks it breaks

uneven pulsar
#

i backup all the photos from my phone, export MAL stuff, update my offline contact lists, important game saves folder, all that jazz

#

find the external hdd, slam all of that there, also put some important stuff on a usb stick

#

also clean registry = speed woosh woosh

real sierra
#

I export nothing

#

everything is cloud nowadays anyway

uneven pulsar
#

i'm low key prepping for the day when google decides i'm not me

#

and never lets me in again, breaking most 2fa i have anywhere else

#

i've seen one too many people locked out of their own cloud backups and online identity, learning the hard way that corpo does in fact not care

real sierra
#

never seen this happen to anyone but I believe you that it can

opaque sigil
#

I should probably look into backups on linux

#

On windows I just did daily snapshots of the boot drive, good enough

uneven pulsar
#

losing your phone is almost a guaranteed rip

#

in an ideal case you have a device at home that is "the usual device" and things will maybe let you change your phone number / turn off 2fa from there

#

but generally the approach is
"oh hey you lost that phone with google authenticator on it? sure we can turn that off, just send us the code from google authenticator on the phone you lost"

opaque sigil
#

Don't use Google authenticator, problem partially solved

uneven pulsar
#

that was the example

#

don't use 2fa

opaque sigil
#

Well no

uneven pulsar
#

unless all factors have a customer service that are forced by law to give you access if you show a govt id
or aren't mandatory

opaque sigil
#

Do use 2fa

uneven pulsar
#

for example SMS-based 2fa is fine as long as you can go to the phone provider and be like "hey lost my phone, give me a new SIM with my old number"

#

authenticator-like stuff is fine if you have a pool of 2-3 devices that all can single-handedly pass every challenge

#

single point of failure 2fa is a bad idea

real sierra
#

SMS 2fa is not fine

#

sim swapping is a disaster

opaque sigil
#

Well duh

uneven pulsar
#

generally anything that you can only do from a phone and not from a computer is bad 2fa

real sierra
#

hardware tokens seem like a good way to do things

#

you can plug them into any device

#

and the keys themselves have a low failure rate ideally

opaque sigil
#

just make sure to get 2 please

uneven pulsar
#

as long as they're not a single point of failure

real sierra
#

yeah its easy to get multiple of a hardware key too

opaque sigil
#

There are also plenty of authenticators that support multiple devices unlike Google's

real sierra
#

i use microsoft authenticator mhm

uneven pulsar
#

it seems like such a "microsoft can't figure this one out" issue

#

but the roles reversed anyway

opaque sigil
#

I think you can actually make it work but you're still bound to phones/emulators unless they changed it (maybe they did I don't use it)

obsidian mantle
#

i get random chest pains too but im a smoker
from what i know it usually is just some nerve being twisted or smth, not dangerous
if it doesnt persist then it should be fine NeuroClueless

#

also im going to install clean win11 for the first time tomorrow on my new pc neuroHypers i hope it doesnt break if there was no update

uneven pulsar
#

do you want to use a local account?

obsidian mantle
#

neuroMonkaOMEGA is there no choice

#

offline install

uneven pulsar
#

also if you're not using ethernet, find drivers for wifi and throw them on the usb stick

uneven pulsar
obsidian mantle
#

no way 💀

#

alright then

uneven pulsar
#

🔹 Command Prompt Trick
On the setup screen, press Shift + F10 to open Command Prompt
Type: start ms-cxh:localonly
This launches a hidden flow that lets you create a local account without needing a Microsoft login

#

you can stil ltry this tho

obsidian mantle
#

gotta get used with times and learn win11 interface at some point
i'll have win10 on my work laptop and win11 at home. sounds nice

uneven pulsar
#

i just switch whenever they release a new one tbh
it's less of a pain the more you do it

#

people who always stick to the old one always switch too, just with extra pain evilGiggle

obsidian mantle
#

i remember when i didnt want to switch xp for 7 neurOMEGALUL
it was so much better, big mistake

uneven pulsar
#

but i can understand that hardware can be an issue neuroNODDERS

#

my internal ranking is XP > 7 > 10 > 8.1 > 11 > 8 > vista

rigid snow
#

lil bro thinks its quantum healing device can revive 💔 fuck you mean "i apologize for the error"

obsidian mantle
#

xp top 1 huh
i have couple of VMs with it for work, its really outdated

uneven pulsar
#

not today, obviously

obsidian mantle
#

oh

#

yeah then its fair

uneven pulsar
#

but it was the peak windows experience

#

i also used 95 98se 2000 and me but i was too little to have reliable grading evilGiggle

obsidian mantle
#

i got my first pc in 2007 and started with xp
and i think there was some app in university that required msdos

#

thats all my experience with old windows

#

oh yeah and some controllers we work with run on debian
holy moly its so bad

uneven pulsar
#

one does not put debian and bad in the same sentence evilSMH

obsidian mantle
#

i dont know what kind of debian they are using there but its incredibly bad

uneven pulsar
#

it could always be more polished and less stable outdated but honestly debian is meant to be like
the slackware of 2005+
you just install it on something and then it runs there for 15 years while everyone forgot

#

at my previous company they ran the call center on debian 4 when debian 9 was out

#

there's some guy who made a server in his garage and put all the touhou OST on it in idk 2011 (400gb of mp3) and slapped some shockwave flash player on top. it runs on the same debian still

obsidian mantle
#

400gb of mp3? neuroMonkaOMEGA
i thought touhou is some game
makes no sense

#

yeah it is

#

how can it be 400gb in mp3

uneven pulsar
#

it's like 20 games but it has a culture of people who make fan covers of its music

obsidian mantle
#

oh

uneven pulsar
#

cause the actual music is some god awful midi

#

also zun is chill about copyright and so are the fans, so it was always easy and fun to just make covers and put them all over the place

#

see that lenny in there

clear sedge
#

( ͡° ͜ʖ ͡°)

real sierra
#

its over for me

uneven pulsar
#

they call it "the cortana sacrifice gambit"

#

in other news, i'm parting ways with VLC

#

with respect and fond memories BijouPray

#

but by the same ethos i ditched everything for VLC, it is now time to become full time mpv

opaque sigil
#

waiting for that vulkan output so i can watch hdr videos with vlc one day

#

tried patching it to build with vulkan support but either i fucked up or it just doesn't work neuroSadge

real sierra
#

i still find it insane that vlc is a valid rtmp sink

glass flower
#

vlc takes ages for me to launch and the skipping around is also slow on larger files annytfOwo is mpv a good alternative?

vagrant grove
#

anyone have experience using Anubis over cloudflare? What's the difference in efficacy like—if there is one?

sage crag
uneven pulsar
uneven pulsar
#

download chrome buttons dont work in edge

#

sometimes i really wish Microsoft was fined for 1/4 of their market value with all the fines going directly to google

real sierra
#

@sage crag added a board clone function if that's useful

clear sedge
uneven pulsar
#

works too

clear sedge
#

then they could kinda chillax with the weird direction they're going in

real sierra
#

sus programmers quiet on Friday...

real sierra
sage crag
real sierra
clear sedge
clear sedge
#

now to write my json parser

rigid snow
real sierra
sage crag
#

what even is life

clear sedge
#

what is love?

#

baby don't hurt me

#

don't hurt me

#

no mo'

sage crag
#

kill you

real sierra
#

code

#

bits byte

#

programmer is such a weird job

sage crag
real sierra
#

imagine describing this to someone 100 years ago

#

"I speak to the thinking machine"

sage crag
#

ye ye thinking machine

#

like me

real sierra
#

I learn the language of the thinking machine and tell it what to do

clear sedge
#

in fact the thinking machine has multiple languages!

real sierra
sage crag
real sierra
#

sometimes there are even many thinking machine

clear sedge
#

some of those languages have dialects

sage crag
#

one language per thinking machine unless your thinking machine is atypical

clear sedge
#

multiple languages that get simplified to a more efficient language depending on which part of the thinking language we're speaking to

#

the eyes of the machine have a different simplified language than the brains!

real sierra
#

some times the thinking machines even imagine thinking machines

clear sedge
#

schizophrenia

sage crag
#

phrr

copper sapphire
#

What happened to MelbaToast project?

#

I remember reading their code a year ago, but haven't seen them since-ish

nocturne olive
#

Hiatus until further notice, all the programmers became unmotivated so the content became stale

copper sapphire
#

huh

real sierra
#

is there a good formula for mapping chess pieces to their approximate value

#

that isn't just a table lookup

restive portal
#

Other than chess notation?

real sierra
#

no I just mean

copper sapphire
#

well, there's if you can use

real sierra
#

for evaluating the score of a board

#

the current evaluation function is just 9*count(QUEEN) + 5*count(ROOK) + ...

#

and I'd love to remove those n* from the front to save tokens

#

I could do it if I had a way to go from those piece constants to approximately the right values

copper sapphire
#

"tokens"?

stray dragon
#

why can't you just do worth[piece] and have piece be a number from 0 to 6 depending on the type of that piece

copper sapphire
#

why are you saving them?

real sierra
#

one idea might be packing all the values in a single number

#

I could do something like

stray dragon
real sierra
stray dragon
#

2 per number

real sierra
#

I would need a number and comma for each value in the array

#

and then to actually index the array

#

if I just have a formula, I can bake it into count and derive it from the piece type

stray dragon
#

compared to 7 per piece this way

real sierra
#

I need the count

#

it's value per piece * number of pieces

#

cant eliminate count(QUEEN)

#

but it's just a macro, I could add things into it

#

so I can replace the constant out front with something in the macro that calculates a constant from the piecetype

stray dragon
#

for(i=64;--i;){total += worth[get_piece_at_index(i)];}

#

done

real sierra
#

thats so many tokens

stray dragon
#

you have the loop macroed

restive portal
#

enum TYPE { KING = 0, QUEEN = 9, ROOK = 5, BISHOP = 3, KNIGHT = 3, PAWN = 1 };

stray dragon
#

that would also work yeah

real sierra
#

my idea is

restive portal
#

I only learned Java. I’m no programmer. I learned enough for basics.

real sierra
#

(char) 0x010303050900ul << piece_type

stray dragon
#

yeah i tried doing something like that

real sierra
#

pack all the weights in a single value

stray dragon
#

wait

real sierra
#

and then shift by the piece type since I know the enum order

stray dragon
#

hmm.

real sierra
#

idk if the cast happens before the shift tho

stray dragon
#

would work a lot better than my implementation

real sierra
#

would cost extra brackets if it does

stray dragon
#

yeah seems good

real sierra
#

YES then I add this to the count macro and my eval fun is just

stray dragon
#

my goofy ass has the piece values as floats so i can't do something that easy

real sierra
#

count(QUEEN) + count(ROOK) + ....

real sierra
#

ints are fine for me

stray dragon
#

yeah but your bot is dum

#

and i want mine to be smort

real sierra
#

my bot only checkmates itself on purpose when it plays black

#

it's not that dum

stray dragon
#

i need the full suite of improvements

fierce badge
#

i did a silly (i would send screenshot but no embed)
since i have dnd on discord, and i have notifs disabled on chrome
i made a python app that notifies me about tutel streams 🙏

stray dragon
#

optimizable parameters like the piece values? gimme that

restive portal
#

Are you adding En passant?

real sierra
#

cast comes before bit shift

#

it's over

#

lose another 2 tokens to parentheses

#

and then the * you'll need after it

#

ultimately it only saves 1 token

#

no wait

#

& comes after <<

#

I can do 0xff & 0x010303050900 << piece_type

#

save 2 tokens

restive portal
#

Also curious how you program Castling.

stray dragon
#

the castling rules suck

real sierra
stray dragon
#

an api that has still not been released

real sierra
#

soon™

#

i promised chayleaf could finish the haskell bindings before it opens

#

they got sidetracked fixing the token counter which was sorely needed, so only fair that i give them a bit more time

real sierra
stray dragon
#

i don't want excuses i want functions

real sierra
#

like

stray dragon
real sierra
#

tbh i was laughing a bit before

#

but you save so many tokens in python

stray dragon
#

i tested it

#

you really don't

real sierra
#

i feel like you do tho

stray dragon
#

you'd think so

real sierra
#

no closing }

#

no free statements

stray dragon
#

which is why i tested it

#

you gain tokens

real sierra
#

no type specifiers

stray dragon
#

it's like 40% gain

real sierra
#

how

stray dragon
#

idfk

#

i implemented the same minimal algorithm as i did in C

#

was like 140 tokens to 100 or so

#

could maybe reduce it with better algorithms that take advantage of the built-in stuff in python

#

but then C has macros

#

i really don't think it's a good option

real sierra
#

that was with the old token counter wasnt it

stray dragon
#

yes but it won't change a thing i don't think

real sierra
#

even with your macros counting for tokens now?

#

idk how bad your macros have gotten but

stray dragon
#

they've always counted for tokens after i found out about that

real sierra
#

im at this point

#define cbclose_return_rv_sc_cbclose_void } return_rv_sc } void
stray dragon
#

i just put them on two lines

#

and they fully count

real sierra
#

i literally

#

moved functions around in my file

obsidian mantle
real sierra
#

so i could use this macro an extra time

obsidian mantle
#

oh its not linear

real sierra
stray dragon
#

but yeah i just do this and the define fully counts the tokens even with the old counter

obsidian mantle
#

do you transform letter of position into number or use it as plain char

real sierra
#

letter of position?

obsidian mantle
#

a b c d

real sierra
#

oh

#

Move objects dont store position as a letter and number

#

it's stored as a bitboard

#

a bitboard represents the chessboard, with one bit for every square:

8 00000000
7 00000000
6 00000000
5 00000000
4 00000000
3 00000000
2 00000000
1 00000000
  abcdefgh
obsidian mantle
#

and what are "ROOK" and "QUEEN"

real sierra
#

integers

#

PAWN, BISHOP, etc all integers

obsidian mantle
#

replace them with counter?

real sierra
#

1 to 6 in ascending value

real sierra
#

its fixed by the api

obsidian mantle
#

are they strings

#

oh you said it

#

soooo

#

still

#

what exact integers

real sierra
#

1 to 6

stray dragon
#

pawn 1

#

king 6

#

guess the rest

obsidian mantle
#

so counter 1 to 6

#

reset before usage

real sierra
#

but i dont just want increasing values for the piece values

stray dragon
#

smh shiro

real sierra
#

2 pawns is not worth a bishop

#

and 3 pawns is not worth a knight

#

it's not a linear relationship

obsidian mantle
#

but there is a multiplier before them

#

9 and 5

real sierra
#

i want to get rid of the multiplier

#

thats the entire problem

stray dragon
#

they mean make a loop, from 1 to 6, and then do something like total+=worth[i]*count(i);

#

for each iteration of the loop

obsidian mantle
#

no i mean

real sierra
#

loop costs more tokens

stray dragon
#

how

#

your loop sucks

real sierra
#

all the variables involved have to be defined

#

my loop doesnt suck RAGEY its 3 tokens

stray dragon
#

then use it?

real sierra
#

its still more tokens

stray dragon
#

how

obsidian mantle
#

wait yes its useless you just replace "piece name" with counter then its 1 to 1

stray dragon
#

smh

real sierra
#

my loop always starts at 0

#

i cant make loops that start at 1

#

that was one of the sacrifices made for tokens

stray dragon
#

make worth an array that starts with a 0 at the 0 pos

#

smh

obsidian mantle
#

can we see the loop that sucks

real sierra
#

then you have to make the array

#

tokens Bruhgi

stray dragon
#

less tokens

#

smh

real sierra
#
#define popdiff(P) 0xff & 0x010303050900 << P * (__builtin_popcountll(chess_get_bitboard(board, WHITE, P)) - __builtin_popcountll(chess_get_bitboard(board, BLACK, P)))
#define eval_score popdiff(QUEEN) + popdiff(ROOK) + popdiff(BISHOP) + popdiff(KNIGHT) + popdiff(PAWN)
#

this is my entire eval fun

#

you're telling me a loop, with all the associated definitions, is fewer tokens?

#

i dont believe it

stray dragon
#

i'm telling you to replace popdiff(QUEEN) + popdiff(ROOK) + popdiff(BISHOP) + popdiff(KNIGHT) + popdiff(PAWN) with a loop

real sierra
#

im telling you its not fewer tokens

stray dragon
#

how.

real sierra
#

because then i need worth and total defined

#

and i need to initialize worth

#

and then the loop itself

stray dragon
#

ngl it seems like way less tokens than all this

real sierra
tender river
obsidian mantle
#

for (int piece : pieces) popdiff(piece) if rook and queen are in a pieces array

rigid snow
tender river
real sierra
#

for (int piece : pieces)

#

i wish

stray dragon
#

just:

worth[7]={0,1,3,3,5,9};
total=0;
for(i=64;--i;){total+=worth[get_piece_at_index(i)];}
#

done

obsidian mantle
#

is it not a thing in c

opaque sigil
#

shiro

stray dragon
#

that's it!

opaque sigil
#

just use g++ already

real sierra
#

im not using c++

#

or anything like it

#

C or nothing

opaque sigil
#

do it for the tokens

stray dragon
real sierra
opaque sigil
real sierra
#

i still have stdbool

rigid snow
stray dragon
#

so stubborn about this, and for what

real sierra
#

i want tokens but im not a monster

opaque sigil
#

you know you can just write c with a c++ compiler right neuroPogHD

stray dragon
real sierra
#

SLOW CatLaughingAtYou

stray dragon
#

LESS TOKEN

real sierra
#

SLOOOOW CatLaughingAtYou

#

i just shrink tokens elsewhere OK it ok

stray dragon
#

this is why you'll fail the contest

#

smh having standards only means you're limiting the things you can do

tender river
stray dragon
#

^^^

real sierra
#

compiler dum

tender river
#

also pass -O3 to gcc

real sierra
#

wont unroll my 64 loop

stray dragon
#

compiler fast

obsidian mantle
#

is "#define" one token or two

stray dragon
#

very fast

obsidian mantle
#

must be two

#

can you define define?

stray dragon
#

loop in c? fastfast

#

do not care about speed of loop in c unless is dumb loop

#

smh

real sierra
obsidian mantle
#

undefined doesnt sound like "doesnt work 100%"

#

or is it crashing everything

opaque sigil
#

#define define 42
this?

obsidian mantle
#

#define define_short #define

opaque sigil
#

yeah nah

obsidian mantle
#

define_short whatever

stray dragon
warped narwhal
opaque sigil
#

you'd have to write a preprocessor for the preprocessor

warped narwhal
#

or you could preprocess multiple times mhm

obsidian mantle
#

if you removed it entirely would it be huge

warped narwhal
real sierra
obsidian mantle
#

optimising some unique thing to get 5 tokens sounds unworth

real sierra
#

im at 1038 tokens

obsidian mantle
#

define global array of ints then access them with macrosed counter

real sierra
#

i only need to shave 14 more

opaque sigil
#

6 for yeeting stdbool

#

actually

#

aren't you compiling with c23

real sierra
#

submissions are gonna be compiled with the same commands lol

obsidian mantle
#

is it nonsense

#

how to access them later tho

real sierra
#

i was this close to reusing argc as a free pointer

obsidian mantle
#

if i do like
#define a_var int my_int
then somewhere do
a_var

can i access it later with my_int?

real sierra
#

but you can also just do

#

int my_int

#

and make a global

#

so the macro isnt doing much

obsidian mantle
#

but i also can int my_int[500]

real sierra
#

?

opaque sigil
real sierra
#

im already using argv

opaque sigil
#

i see

real sierra
#

argc is a char * but you can just set that to anything

#

all pointers are the same size

#

would be great for storing my tree struct

opaque sigil
#

what

real sierra
#

sadly my macros all have tree built into them already for that

opaque sigil
#

argc is not a pointer

real sierra
#
int main(int argc, char *argv[] bclose
#

OH

#

i do mean argv

opaque sigil
#

now that makes more sense

real sierra
#

Dentgetyping"argc is pointer"

#

sorry i cant read non-macros

opaque sigil
#

idk if it's safe to reuse the memory from argc

#

4 bytes is 4 bytes

real sierra
#

im not reusing the contents of the array

#

im reusing the pointer itself

#

argv as a pointer is just a value on the stack

opaque sigil
#

yeah that's what i meant

real sierra
#

do you think changing the value in argc is gonna break things after i return?

opaque sigil
#

take a pointer to argc and use that for whatever you want

real sierra
#

seems like it'd be a const * if so

opaque sigil
#

idk

real sierra
#

where can i even save tokens anymore

opaque sigil
#

yeet stdbool

real sierra
#

stdbool my beloved

opaque sigil
#

and either target c23 or use a c++ compiler

real sierra
#

i will target c23 OK

obsidian mantle
opaque sigil
#

could break if you rely on things being implicitly ints thanks to c89

obsidian mantle
#

my_int vs int my_int

opaque sigil
real sierra
#

i dont see why you wouldnt just

#
#define my_int int x ## __COUNTER__ = 0;
#

why the array

opaque sigil
#

i'd also recommend looking into replacing things with things from the c++ stl but i guess i know how you feel about that shiro om

real sierra
#

death before dishonor

#

where "death" is "too many tokens"

#

and "dishonor" is "c++"

#

the biggest annoyance for me is rand RAGEY

#

it requires stdlib

#

only dependency on it that i have left

#

and making my own rand is too many tokens

obsidian mantle
stray dragon
#

here's how i replaced it:

real sierra
#

that doesnt exist

stray dragon
#

does it not?

real sierra
#

it doesnt

#

i checked

stray dragon
#

aw

real sierra
#

i literally scrolled the full list of builtins to find useful ones

stray dragon
#

you should try it though

opaque sigil
#

are you using clang t

real sierra
#

wdym

#

it isnt there

stray dragon
real sierra
#

once chayleaf finishes haskell bindings, contest starts

stray dragon
#

i did test rand in an online c compiler though

real sierra
stray dragon
#

it worked

#

with the builtin

rigid snow
#

cool

stray dragon
#

i don't think the "list of builtins" shows everything

obsidian mantle
#

this is better

stray dragon
#

it didn't show __builtin_pow, yet that exists and works

obsidian mantle
#

i forgot why do i need array

opaque sigil
#

i would love to know what weird compiler you were using

#

neither gcc nor clang have __builtin_rand for me

opaque sigil
#

same with tcc

#

i'm not testing msvc

real sierra
#

you will notice that rand is absent from this page

#

my compiler is gcc so you should expect these builtins to exist (i'll add this info to the github readme)

stray dragon
#

aw man

obsidian mantle
stray dragon
#

you're right

#

builtin rand doesn't exist

#

builtin pow does though

#

weird.

real sierra
#

yeah idk why rand isnt a builtin