#Greedy algo improvements

35 messages · Page 1 of 1 (latest)

pallid panther
#

My question got RIP'd for some reason

void vessel
#

probably because file attached

pallid panther
#

same question

void vessel
#

step 1: rewrite it in rust

pallid panther
#

Yea, I was thinking that but I only know python somewhat, so I was thinking to write it in python and ask chatgpt to rewrite it once the logic is down

void vessel
#

Don't chatgpt

#

step 2: profile to see what part is taking ages

pallid panther
#

No choice if I want it faster.. I don't know rust 😒

void vessel
#

Learn Rust 🗣️

void vessel
pallid panther
#

The issue isnt the program taking long, I realise now when I said runtime is too high it might be confusing but I meant run time from the file names(the attacks its choosing)

#

For example when choosing 93% coverage, its giving me 1000 attack chains(that only reach 91%) that takes 100days. When I know that I can achieve 93% in under 4 hours from figuring it out manually

void vessel
#

So the entire algorithm is trash? lmao

pallid panther
#

Pretty much ngl

#

It's why I need somebody who knows how to improve this.

void vessel
#

!rule solicitation

lethal sleetBOT
#
Promotion

We're not a job board & do not allow the exchange of money. We also ask that you keep self-promotion to a minimum.

If you have something you think we'd like to promote talk to the mods.

void vessel
#

🗣️

pallid panther
#

Fair enough

void vessel
#

I don't even get how that algorithm is supposed to work

pallid panther
#

Basically it goes through all plains in all files in setA folder. Checks how long each file takes, divises some sort of plain coverage to time taken ratio and chooses the best one. Then it looks at all the files again and finds plains that arnt in the first one, does the ratio and selects the best one, and so on.

void vessel
#

"How long each file takes" how's the runtime relevant to the algo?

pallid panther
#

We are looking for the shortest runtime that achieves a certain coverage

#

by runtime we mean the seconds int taken from the file names

void vessel
#

So not actually runtime of our code lol just a property of that file

pallid panther
#

yea exactly

void vessel
#

Seems like you might never achieve a path with the desired chance?

pallid panther
#

Once it tips over or reaches plains needed, we stop

#

but yes, often it doesnt reach

#

because it chooses bad attack paths

void vessel
#

I just realized this probably is one of those weird turn-based mobile games

#

😭

pallid panther
#

Erm, na..