• Hey Guest! It's back and bigger than ever, your official cricket league; The PlanetCricket League Season 4 Sign-Ups are now open . Head over to this page to book your participation.

Manish's Simulators - T10, The Hundred, Twenty Twenty, List A

Manish.

Staff Member
Moderator
India
SRH...
PlanetCricket Award Winner
Joined
Aug 22, 2016
Location
Vijayawada, India.
Profile Flag
India
Online Cricket Games Owned
  1. Don Bradman Cricket 14 - Steam PC
sim~1.jpg

INTRODUCTION

Hello All & Welcome to my simulators thread. I have been on this forum since August 2016. Started my journey with Cricket 07 mods and then progressed to cricket leagues. My passion for tech and addiction to Planet Cricket made me develop these simulators. Started developing these in the month of March 2021 and took 10 months to bring them to a perfect shape and improvements suggested from our members. Today I present four simulators here, which include The Hundred, T10, T20, and List A.


INSTALLATION

I have planned for 2 versions of user experiences. The first is using python and the other is a standalone application (this will take a little time).
Python Installation
  • Go to the official python website https://www.python.org/downloads/release/python-398/
  • Scroll to the end of the page and there you can find the list of available files for various operating systems.
  • Choose the one which suits best to your machine based on the x32/x64 bit processor.
  • Once the download is finished, right-click on .exe file and select run as administrator.
  • On the open screen, make sure you select 'Add Python 3.9 to PATH'.
  • Wait for a few seconds to complete the installation.

Packages Installation
  • Open your terminal/cmd.
  • Now type, 'pip install pandas' and hit enter. Wait for a few seconds to download and install the package.
  • After the completion of the above step, type 'pip install tabulate' and hit enter.
If these are done successfully, we are ready to sim matches. If you face any difficulties in installation post them here in this thread along with screenshots.
 
Last edited:

Manish.

Staff Member
Moderator
India
SRH...
PlanetCricket Award Winner
Joined
Aug 22, 2016
Location
Vijayawada, India.
Profile Flag
India
Online Cricket Games Owned
  1. Don Bradman Cricket 14 - Steam PC
T10 LEAGUE

INTRODUCTION


It's a ten overs innings simulator. This simulator is available in 2 versions. The first one, you can generally set up your squads and run the sim, such that the simulator wholly carries on the simulation without your interaction with it. The second comes up with manual bowling options. The simmer can choose who should bowl the next over in the spell. You have the feasibility to add more commentary lines of your choice to the text files inside the commentary folder. By default, this simulator has five-pitch types, namely Flat, Hard, Dry, Normal, Green, and Dusty. To experience more reality games prefer using Flat/Normal wickets.

TEAMS CREATION
You have been given two folders in the downloaded folder, namely t10_auto template, and t10_manual template, and two other teams' data in each folder configured and used for different leagues. You can use that template in creating new squads and matching data for reference.

T10 Auto
  1. The CSV file name will be your team name. Please copy the template and rename it with your team name.
  2. The first column is 'player,' where you can your player name.
  3. The second column is in 'role.' There are three roles present. 'Batsman,' 'Bowler,' and 'Keeper.' Even mark allrounder as a bowler. Everything is case-sensitive in this excel sheet. So be careful while you are editing.
  4. The third col is just for user reference. You can type in your note like players' auction prices or anything such that it will be easy for you to rate them. You can even leave it empty but make sure you don't delete that column.
  5. The columns 0s to no-ball are actual ratings for the particular player. Based on players' real-time performance, you can rate them. How many dot balls will he be playing, and how many 1s and 2s he take. Make sure you don't set 'leg bye,' 'wide,' and 'no ball' more significant than 2 or 3.
  6. The last columns, 'bowling_action,' have two categories: a bowler is 'spin' or 'fast.' Col 'bowling_points' determine his performance. Don't rate bowlers greater than 90.

T10 Manual
  1. Follow completely as mentioned in T10 Auto.
  2. In the CSV file, you can notice there are cells noted with Over 1, Over 2, and so on. Replace those with your bowling order.
For auto simulation - min 6 bowlers are required.
For manual simulation - min 5 bowlers are required.

SIMULATION
  1. Go to T10 and open cmd/terminal at that location.
  2. Copy your teams' data from respective folders to the main root folder.
  3. In cmd type 'python the t10_auto.py' for auto version or 'python t10_manual.py' for the manual version. Hit enter.
  4. Now you will be displayed with the available teams.
  5. Enter the index no of team1 and team 2 from the displayed list you want.
  6. Type your pitch type from the given display.
  7. The match will be simulated and the output will be stored in 'team 1 vs team 2 - timestr' folder.
  8. If the simulation is successful you will find 5 files in the above folder.

STATS CALCULATION
  1. After every match simulation, 4 CSV files are stored in a particular match folder.
  2. Separate batsmen and bowler data to any new folder.
  3. Open cmd from the T10 folder and type 'python t20 cricket_stats.py'.
  4. A GUI application will be opened and you have to choose batsmen and bowler's CSV files there.
  5. Click compute, the output will be stored in the stats-calculator folder in the form of CSV and text files.
 

Attachments

  • T10.zip
    43.1 KB · Views: 4

Manish.

Staff Member
Moderator
India
SRH...
PlanetCricket Award Winner
Joined
Aug 22, 2016
Location
Vijayawada, India.
Profile Flag
India
Online Cricket Games Owned
  1. Don Bradman Cricket 14 - Steam PC
THE HUNDRED

INTRODUCTION


It's a 100 ball innings simulator. This simulator is available in 2 versions. The first one you can generally set up your squads and run the sim, such that the simulation is completely carried on by the simulator without your interaction with it. The second comes up with manual bowling options. The simmer can choose who should bowl the next10 balls or 5 balls in the spell. You have the feasibility to add more commentary lines of your choice to the text files inside the commentary folder. By default, this simulator comes up with 5 pitch types namely Flat, Hard, Dry, Normal, Green, and Dusty.

TEAMS CREATION
In the downloaded folder, you have been given a template and 2 others teams' data which is configured and used for other leagues. You can use that template in creating new squads and matching data for reference.

  1. The CSV file name will be your team name. Make a copy of the template and rename it with your team name.​
  2. The first column is 'player' where you can your player name.​
  3. The second column is in 'role', at present, there are 3 roles. 'Batsman', 'Bowler', and 'Keeper'. Even mark allrounder as bowler. Everything is case-sensitive in this excel sheet. So be careful while you are editing.​
  4. The third col is just for user reference, you can type in your note like players auction price or anything such that it will be easy for you to rate them. You can even leave it empty but make sure you don't delete that column.​
  5. The columns 0s to no-ball are actual ratings for the particular player. Based on players' real-time performance you can rate them. How many dot balls he will be playing, how many 1s and 2s he will take. Make sure you don't set 'leg bye', 'wide', and 'no ball' greater than 2 or 3.​
  6. The last columns 'bowling_action' has two categories either a bowler is 'spin' or 'fast'. Col 'bowling_points' determine his performance. Don't rate bowlers greater than 90.​

For auto simulation - min 6 bowlers are required.
For manual simulation - min 5 bowlers are required.

SIMULATION
  1. Go to The Hundred folder and open cmd/terminal at that location.​
  2. In cmd type 'python the 100_auto.py' for auto version or 'python the 100_manual.py' for the manual version. Hit enter.​
  3. Now you will be displayed with the available teams.​
  4. Enter the index no of team1 and team 2 from the displayed list you want.​
  5. Type your pitch type from the given display.​
  6. The match will be simulated and the output will be stored in 'team 1 vs team 2 - timestr' folder.​
  7. If the simulation is successful you will find 5 files in the above folder.​
For Manual version - Follow the same steps as above, but at the end of every 5 and 10 balls, you will be shown the player names and no fo balls they bowled. So choose whom you to want to bowl next by entering the number shown next to the bowler's name.

STATS CALCULATION
  1. After every match simulation, 4 CSV files are stored in a particular match folder.​
  2. Separate batsmen and bowler data to any new folder.​
  3. Open cmd from The Hundred folder and type 'python cricket_stats.py'.​
  4. A GUI application will be opened and you have to choose batsmen and bowler's CSV files there.​
  5. Click compute, the output will be stored in the stats-calculator folder in the form of CSV and text files.​
 

Attachments

  • The Hundred.zip
    42 KB · Views: 10

Manish.

Staff Member
Moderator
India
SRH...
PlanetCricket Award Winner
Joined
Aug 22, 2016
Location
Vijayawada, India.
Profile Flag
India
Online Cricket Games Owned
  1. Don Bradman Cricket 14 - Steam PC
TWENTY-TWENTY

INTRODUCTION

It's a 20 overs innings simulator. This simulator is available in 2 versions. The first one you can generally set up your squads and run the sim, such that the simulation is completely carried on by the simulator without your interaction with it. The second comes up with manual bowling options. The simmer can choose who should bowl the next over in the spell. You have the feasibility to add more commentary lines of your choice to the text files inside the commentary folder. By default, this simulator comes up with 5 pitch types namely Flat, Hard, Dry, Normal, Green, and Dusty.

TEAMS CREATION
You have been given two folders in the downloaded folder, namely t20_auto template, and t20_manual template, and two other teams' data in each folder configured and used for different leagues. You can use that template in creating new squads and matching data for reference.

T20 Auto
  1. The CSV file name will be your team name. Please copy the template and rename it with your team name.
  2. The first column is 'player,' where you can your player name.
  3. The second column is in 'role.' There are three roles present. 'Batsman,' 'Bowler,' and 'Keeper.' Even mark allrounder as a bowler. Everything is case-sensitive in this excel sheet. So be careful while you are editing.
  4. The third col is just for user reference. You can type in your note like players' auction prices or anything such that it will be easy for you to rate them. You can even leave it empty but make sure you don't delete that column.
  5. The columns 0s to no-ball are actual ratings for the particular player. Based on players' real-time performance, you can rate them. How many dot balls will he be playing, and how many 1s and 2s he take. Make sure you don't set 'leg bye,' 'wide,' and 'no ball' more significant than 2 or 3.
  6. The last columns, 'bowling_action,' have two categories: a bowler is 'spin' or 'fast.' Col 'bowling_points' determine his performance. Don't rate bowlers greater than 90.

T10 Manual
  1. Follow completely as mentioned in T20 Auto.
  2. In the CSV file, you can notice there are cells noted with Over 1, Over 2, to Over 20. Replace those with your bowling order.
For auto simulation - min 6 bowlers are required.
For manual simulation - min 5 bowlers are required.

SIMULATION
  1. Go to T20 and open cmd/terminal at that location.
  2. Copy your teams' data from respective folders to the main root folder.
  3. In cmd type 'python the t20_auto.py' for auto version or 'python t20_manual.py' for the manual version. Hit enter.
  4. Now you will be displayed with the available teams.
  5. Enter the index no of team1 and team 2 from the displayed list you want.
  6. Type your pitch type from the given display.
  7. The match will be simulated and the output will be stored in 'team 1 vs team 2 - timestr' folder.
  8. If the simulation is successful you will find 5 files in the above folder.
STATS CALCULATION
  1. After every match simulation, 4 CSV files are stored in a particular match folder.
  2. Separate batsmen and bowler data to any new folder.
  3. Open cmd from the T20 folder and type 'python t20 cricket_stats.py'.
  4. A GUI application will be opened and you have to choose batsmen and bowler's CSV files there.
  5. Click compute, the output will be stored in the stats-calculator folder in the form of CSV and text files.
 

Attachments

  • T20.zip
    43.1 KB · Views: 19

Manish.

Staff Member
Moderator
India
SRH...
PlanetCricket Award Winner
Joined
Aug 22, 2016
Location
Vijayawada, India.
Profile Flag
India
Online Cricket Games Owned
  1. Don Bradman Cricket 14 - Steam PC
End of The Hundred Development
Nearly on working for 9 months got the perfect algorithm for the cricket simulator. Started with the hundred and it continued with T10, T20, and List A (Yet to release). So today we have the hundred in perfect stage and available for public release. Therefore I'll be discontinuing the development of this simulator in order to focus more on T20 and List A so it can reach a wider audience and one day use it for our official leagues.

A big thanks to @Na Maloom Afraad @Parth D @RUDI @Till Valhalla (no particular order) for all the suggestions and your time testing and responses in our conversation group.
And there goes helpful poster medal to @Pinch hitter for all his round-the-clock feedback, testing all builds on day 1, and giving me feedback. Improving the ratings. Today if my Hundred and T20 sims are giving good results (compared to one's most available at present) he is the big guy behind it.
 

Parth D

ICC Chairman
PlanetCricket Award Winner
Champions League Winner
Avengers
Joined
Mar 27, 2014
Really impressed by your work @Manish. Quiet innovative and fresh concept. And for a person to code and develop it all alone, it takes a lot and lot of hardwork and passion. You're a champ.

Also, I honestly don't know why my name is up there. I literally contributed nothing. Instead I can say I got lucky to be able to witness this amazing work from behind the scenes.
 

Colin Wilson

School Cricketer
Joined
Jun 10, 2019
I have tried everything, but the command prompt doesn't seem to be doing anything when I type in the launch. I've tried the cmd in the python folder as well.
 

Attachments

  • Screenshot 2022-01-19 210304.png
    Screenshot 2022-01-19 210304.png
    403.1 KB · Views: 14

Manish.

Staff Member
Moderator
India
SRH...
PlanetCricket Award Winner
Joined
Aug 22, 2016
Location
Vijayawada, India.
Profile Flag
India
Online Cricket Games Owned
  1. Don Bradman Cricket 14 - Steam PC
I have tried everything, but the command prompt doesn't seem to be doing anything when I type in the launch. I've tried the cmd in the python folder as well.
try this command, put the file name within quotes
Code:
python "the 100_auto.py"
 

Manish.

Staff Member
Moderator
India
SRH...
PlanetCricket Award Winner
Joined
Aug 22, 2016
Location
Vijayawada, India.
Profile Flag
India
Online Cricket Games Owned
  1. Don Bradman Cricket 14 - Steam PC
Should I improve the simulator compatible with AI (We can simulate historical matches with custom squads) and web channel instead of running scripts/standalone applications?
 

asprin

Mr. Fixit
Admin
Sportsbookie
India
PlanetCricket Award Winner
Joined
Sep 3, 2012
Location
Hyderabad, India
Profile Flag
India
Online Cricket Games Owned
  1. Don Bradman Cricket 14 - Steam PC
Should I improve the simulator compatible with AI (We can simulate historical matches with custom squads) and web channel instead of running scripts/standalone applications?
Web channel sounds good. I'm leaning django currently :D
 

Manish.

Staff Member
Moderator
India
SRH...
PlanetCricket Award Winner
Joined
Aug 22, 2016
Location
Vijayawada, India.
Profile Flag
India
Online Cricket Games Owned
  1. Don Bradman Cricket 14 - Steam PC
Web channel sounds good. I'm leaning django currently :D
That's great.
Not exactly a web application but I'll integrate the simulator on web chatbots. So that users can access this using WhatsApp and telegram too.
 

Users who are viewing this thread

Top