Python Forum
Search Results
Post Author Forum Replies Views Posted [asc]
    Thread: Loop to find the best combination/score
Post: RE: Loop to find the best combination/score

Thanks for all your tests. I started to do a C++ program, so far I succeeded to get my 400 players almost instantly with some rand% for the values. Now I am looking for the loop/combinations, my few...
KoinKoin Homework 21 29,239 Jan-05-2023, 10:31 AM
    Thread: Loop to find the best combination/score
Post: RE: Loop to find the best combination/score

(Jan-04-2023, 06:15 AM)deanhystad Wrote: Timing is less deterministic using this approach, but a very rough estimate for creating teams with a pool of 200 players is 6.3 minutes, and 3.5 hours for a...
KoinKoin Homework 21 29,239 Jan-04-2023, 09:44 AM
    Thread: Loop to find the best combination/score
Post: RE: Loop to find the best combination/score

I might be crazy asking that, but what if I have like 400 players and I need the best 5 ? It's like 84 billions combinations possible... I tried to play with that but I got a "Memory error" at some po...
KoinKoin Homework 21 29,239 Jan-02-2023, 09:44 PM
    Thread: Loop to find the best combination/score
Post: RE: Loop to find the best combination/score

I already know that this code : for index in list(combinations(df1.index,5)):     dictIndexScore[index] = df1.loc[index,:]["Score1"].sum(axis=0)is taking long time, I already saw that without cProfile...
KoinKoin Homework 21 29,239 Dec-31-2022, 05:44 PM
    Thread: Loop to find the best combination/score
Post: RE: Loop to find the best combination/score

Wow thank you very much @deanhystad ! I adapted it to my script and work great! May I ask the difference between my code and yours ? I feel like the step was the same, only the method was different. ...
KoinKoin Homework 21 29,239 Dec-31-2022, 03:48 PM
    Thread: Loop to find the best combination/score
Post: RE: Loop to find the best combination/score

Hello everyone, I modified my code, it should be faster than the last one above, but still pretty long when I need to find 5 of 60... Instead of comparing every combination like before, I putting in ...
KoinKoin Homework 21 29,239 Dec-30-2022, 04:50 PM
    Thread: Loop to find the best combination/score
Post: RE: Loop to find the best combination/score

Finally, I found some solution : I'm doing the combination on all my dataframe, then for each combination, calculate the 10average and if it's under 121, comparing with previous bestSum... bestSum = ...
KoinKoin Homework 21 29,239 Dec-29-2022, 11:38 PM
    Thread: Loop to find the best combination/score
Post: RE: Loop to find the best combination/score

Yes, it is correct, sorry that my words are difficult to understand Sum should be the highest possible. And the 5 players selected to get the highest score should be in the limit of "MVP + 120" (or su...
KoinKoin Homework 21 29,239 Dec-29-2022, 09:23 PM
    Thread: Loop to find the best combination/score
Post: RE: Loop to find the best combination/score

Score is what determine the better team. I would like to find the highest score possible in the limit of MVP + 120
KoinKoin Homework 21 29,239 Dec-29-2022, 08:54 PM
    Thread: Loop to find the best combination/score
Post: RE: Loop to find the best combination/score

(Dec-29-2022, 07:48 PM)deanhystad Wrote: The MVP will be the same player for every team. If Luka costs nothing, Luka will be the MVP for all top teams. Now you need to create teams of 4 from the r...
KoinKoin Homework 21 29,239 Dec-29-2022, 08:42 PM
    Thread: Loop to find the best combination/score
Post: RE: Loop to find the best combination/score

Oh it was moved... It's not a homework, so I think you consider that as no effort... I can't put everything that I have in my head, sorry If you want to know, one of my best solution would be to tak...
KoinKoin Homework 21 29,239 Dec-29-2022, 06:23 PM
    Thread: Loop to find the best combination/score
Post: Loop to find the best combination/score

Hello everyone, I need your help because I can't a good solution of my problem I have a dataframe, with name of some NBA players, average number and score, it looks like that : Quote: PLAYERS 10Aver1...
KoinKoin Homework 21 29,239 Dec-29-2022, 05:45 PM
    Thread: Webscrapping sport betting websites
Post: RE: Webscrapping sport betting websites

Hello snippsat, thanks for your reply. You're right, in the network data, I already saw that json, unfortunately, you only have 2 bets available : "Match Result" and "Double Chance". There are other t...
KoinKoin Web Scraping & Web Development 3 5,636 Mar-19-2022, 07:44 PM
    Thread: Webscrapping sport betting websites
Post: Webscrapping sport betting websites

Hello everyone, As part of my improvement in Python, I want to scrap some sport betting websites and try to compare the odds. I have few websites on my mind and for 2 of them, I was able to find a we...
KoinKoin Web Scraping & Web Development 3 5,636 Mar-19-2022, 10:07 AM
    Thread: New Users Introduce Yourself
Post: RE: New Users Introduce Yourself

(Mar-18-2022, 05:45 PM)Gribouillis Wrote: @KoinKoin If it quacks like a duck... Quack-quack !
KoinKoin Bar 432 235,159 Mar-19-2022, 09:26 AM
    Thread: New Users Introduce Yourself
Post: RE: New Users Introduce Yourself

Hi everyone, I'm a French guy (sorry for my English mistakes **biggrin** ), who did for almost 10 years Java programming. I'm in a state of mind where I want/need some changes. So I'm sort of new t...
KoinKoin Bar 432 235,159 Mar-18-2022, 05:21 PM

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020