Horse Racing Forum - PaceAdvantage.Com - Horse Racing Message Board

Go Back   Horse Racing Forum - PaceAdvantage.Com - Horse Racing Message Board > Off Topic > Off Topic - Computers


Reply
 
Thread Tools Rating: Thread Rating: 7 votes, 5.00 average.
Old 01-02-2017, 12:38 PM   #301
traynor
Registered User
 
traynor's Avatar
 
Join Date: Jan 2005
Posts: 6,626
Quote:
Originally Posted by DeltaLover
Since you are redesigning / reimplementing, I suggest a test driven development making a 100% testing coverage a goal. Although your initial speed might be a notch slower you must resist the temptation of adding "naked" components (meaning without related tests) since this approach will result to much higher level quality of code that will be easier to maintain and evolve as time goes by. Also, you might find some interesting ideas in Literate programming which might become helpful in some phases of your migration. Also check your PM for a link to one of articles that I have written about test driven approach and a video that I have put together.
I have been using TDD for quite awhile. Unless one has written subs that wander on for hundreds and hundreds of lines--that do what one intended but break at some time in the future and require a LOT of thought and work to fix--one cannot truly appreciate the need for TDD, small modules, and clear comments. (And always, always updating the comments to be current with the code.) There are few things more dismaying than trying to decipher clear, concise comments describing the intent and purpose of a block of code that (now) does something quite different from what it did when the comments were written.
traynor is offline   Reply With Quote Reply
Old 01-11-2017, 10:58 AM   #302
traynor
Registered User
 
traynor's Avatar
 
Join Date: Jan 2005
Posts: 6,626
Something you may want to consider, especially if you use Microsoft technologies.

https://blogs.technet.microsoft.com/...T&MC=MobileDev

There is little point in re-inventing the wheel, if one's intent is to use the wheel to facilitate going from point A to point B. Lots of very useful stuff (fairly) readily available to average users. No PhD in Predictive Analytics required. As usual, Microsoft does all the heavy lifting behind the scenes and makes it all look incredibly simple.

If you have ever considered "deep learning" about horse races, this might well be the most useful tool to consider in that endeavor.
traynor is offline   Reply With Quote Reply
Old 01-11-2017, 12:26 PM   #303
JJMartin
Registered User
 
JJMartin's Avatar
 
Join Date: Jun 2011
Posts: 588
Quote:
Originally Posted by traynor
Something you may want to consider, especially if you use Microsoft technologies.

https://blogs.technet.microsoft.com/...T&MC=MobileDev

There is little point in re-inventing the wheel, if one's intent is to use the wheel to facilitate going from point A to point B. Lots of very useful stuff (fairly) readily available to average users. No PhD in Predictive Analytics required. As usual, Microsoft does all the heavy lifting behind the scenes and makes it all look incredibly simple.

If you have ever considered "deep learning" about horse races, this might well be the most useful tool to consider in that endeavor.
I have tried applying neural networks to large pp samples several times now with disapointing but not unexpected results. I think the deep learning technology applied to horse racing would probably yield impressive results based on visual information as has been demonstrated in other areas already. Perhaps if it was fed several thousand still images of real race horses or race replays with some consistency in distance,surface and race view angles, it could be a gold mine find. It would definitely see things that human perception is oblivious to.
JJMartin is offline   Reply With Quote Reply
Old 01-12-2017, 01:15 AM   #304
traynor
Registered User
 
traynor's Avatar
 
Join Date: Jan 2005
Posts: 6,626
Quote:
Originally Posted by JJMartin
I have tried applying neural networks to large pp samples several times now with disapointing but not unexpected results. I think the deep learning technology applied to horse racing would probably yield impressive results based on visual information as has been demonstrated in other areas already. Perhaps if it was fed several thousand still images of real race horses or race replays with some consistency in distance,surface and race view angles, it could be a gold mine find. It would definitely see things that human perception is oblivious to.
You might find it useful to search a smaller set, purely to locate possible trends, then to search for those trends in a larger set. Too big a set initially blurs what could become very interesting (and useful). In essence, the reverse process of using a large data set to "prove" that whatever was discovered in the small set "won't work in the real world."

Also, you may find it more useful to ignore ROI (initially) and go straight for the win frequency as a target category. That lets you do some useful research without being misled by (a relatively small number of) outliers.
traynor is offline   Reply With Quote Reply
Old 01-12-2017, 07:53 AM   #305
Actor
Librocubicularist
 
Join Date: Jun 2010
Location: Ohio
Posts: 10,466
Quote:
Originally Posted by highnote
Here is basic language code for Dick Mitchell's "Positive Expectation Handicapping" software. I believe this was in one of his books.

You might need to adjust some of the lines to make it work. It's a command line program.

This is the code I used to begin to learn how to write code for horse racing.



Code:
10 B$ = Chr$(7)
   Dim CL(20), CW(20), ES(20), FR(20), LS(20), RS(20), SP(20), XX(20),       Z1(20), Z2(20), Z3(20), Z5(20), Z6(20), Z7(20)
   Dim CM(20), CN(20), ML(20), P(20), S(20), K(20), L(20), MS(20), CF(20)

40 For I = 1 To 25: Print: Next I
50 INPUT "ENTER TODAY'S DATE "; A$
   GoSub 3400
   If FU$ = "" Then DA$ = A$: GoTo 90
What does the variable FU$ stand for?
Actor is offline   Reply With Quote Reply
Old 01-12-2017, 08:01 AM   #306
DeltaLover
Registered user
 
DeltaLover's Avatar
 
Join Date: Oct 2008
Location: FALIRIKON DELTA
Posts: 4,439
Quote:
Originally Posted by Actor
What does the variable FU$ stand for?
Check what is happening in line 3400 and after..

By the way, this "code" is the perfect example why to avoid basic and you should not try to learn anything from it as it represents an extremely poor approach.
__________________
whereof one cannot speak thereof one must be silent
Ludwig Wittgenstein
DeltaLover is offline   Reply With Quote Reply
Old 01-12-2017, 05:18 PM   #307
Actor
Librocubicularist
 
Join Date: Jun 2010
Location: Ohio
Posts: 10,466
Quote:
Originally Posted by DeltaLover
Check what is happening in line 3400 and after..
Obviously a status message since it gets assigned values like 'ERROR', 'FOUND', 'F' or just ''. Why FU$ instead of ST$ or ER$ ?

Quote:
Originally Posted by DeltaLover
By the way, this "code" is the perfect example why to avoid basic and you should not try to learn anything from it as it represents an extremely poor approach.
Obviously written for a primitive version of BASIC which did not provide WHILE .. WEND or IF .. THEN .. ELSE, but not so primitive that it required a line number on each line. Second to the huge number of GOTOs its biggest fault is a complete lack of REMs.

It intrigues me. It computes an odds line for each race (I think) but I have not been able to figure out the algorithm. If I can do that then I'll try rewriting it in Free Pascal using BRIS files for input instead of the totally manual input.

Thanks for your input.
Actor is offline   Reply With Quote Reply
Old 01-12-2017, 05:47 PM   #308
traynor
Registered User
 
traynor's Avatar
 
Join Date: Jan 2005
Posts: 6,626
I used it. It was a big time loser then, probably (would be) even more so now. One of my fondest memories is of Mitchell (very aggressively) "explaining" why it didn't work (at a Sartin seminar). Oddly enough, Mitchell never offered to refund the money the chumps paid for his app. A big surprise. Did anyone, anywhere, ever do anything with it that even vaguely approached living up to the hype?

Anyone know whatever happened to David Akimoto (I think the name is correct, but may be off a bit), the guy who actually developed the app? Smart kid.
traynor is offline   Reply With Quote Reply
Old 01-12-2017, 05:54 PM   #309
DeltaLover
Registered user
 
DeltaLover's Avatar
 
Join Date: Oct 2008
Location: FALIRIKON DELTA
Posts: 4,439
Quote:
Originally Posted by Actor
Obviously a status message since it gets assigned values like 'ERROR', 'FOUND', 'F' or just ''. Why FU$ instead of ST$ or ER$ ?

Obviously written for a primitive version of BASIC which did not provide WHILE .. WEND or IF .. THEN .. ELSE, but not so primitive that it required a line number on each line. Second to the huge number of GOTOs its biggest fault is a complete lack of REMs.

It intrigues me. It computes an odds line for each race (I think) but I have not been able to figure out the algorithm. If I can do that then I'll try rewriting it in Free Pascal using BRIS files for input instead of the totally manual input.

Thanks for your input.
I understand, reverse engineering Basic code especially written with a lot of GOTO is not a fun task.

The input should be transparent to your procedure and be able to switch from BRIS to manual to whatever else just by altering a configuration setting.

Quote:
Originally Posted by Actor
Obviously a status message since it gets assigned values like 'ERROR', 'FOUND', 'F' or just ''. Why FU$ instead of ST$ or ER$ ?
Try to avoid status messages as much as you can, use exceptions instead.
__________________
whereof one cannot speak thereof one must be silent
Ludwig Wittgenstein

Last edited by DeltaLover; 01-12-2017 at 05:55 PM.
DeltaLover is offline   Reply With Quote Reply
Old 01-12-2017, 06:04 PM   #310
traynor
Registered User
 
traynor's Avatar
 
Join Date: Jan 2005
Posts: 6,626
Quote:
Originally Posted by JJMartin
I have tried applying neural networks to large pp samples several times now with disapointing but not unexpected results. I think the deep learning technology applied to horse racing would probably yield impressive results based on visual information as has been demonstrated in other areas already. Perhaps if it was fed several thousand still images of real race horses or race replays with some consistency in distance,surface and race view angles, it could be a gold mine find. It would definitely see things that human perception is oblivious to.
One of the funniest comments I have seen since a professor at the University of Washington described a class I was considering as "calculus for poets."

"The Python backing extends the toolkit beyond C++ development for better accessibility. C++ "was good for really serious programmers," said XD Huang, Microsoft chief speech scientist, but "our mission is simple: to democratize AI," not only for web developers, but for different disciplines, even sociologists. Python support will offer extensiveness, expressiveness, and flexibility."
http://www.infoworld.com/article/313...g-toolkit.html

If "even sociologists" can use it, it MUST be simple.
traynor is offline   Reply With Quote Reply
Old 01-12-2017, 06:18 PM   #311
DeltaLover
Registered user
 
DeltaLover's Avatar
 
Join Date: Oct 2008
Location: FALIRIKON DELTA
Posts: 4,439
Quote:
Originally Posted by traynor
If "even sociologists" can use it, it MUST be simple.
It is true that python is simple in the sense that it allows a complete beginner to start writing simple programs very quickly but in reality it has a significant learning curve if you want to reach expert levels and write idiomatic code using concepts like meta-classes, decorators, coroutines, context managers etc.
__________________
whereof one cannot speak thereof one must be silent
Ludwig Wittgenstein
DeltaLover is offline   Reply With Quote Reply
Old 01-12-2017, 06:18 PM   #312
Actor
Librocubicularist
 
Join Date: Jun 2010
Location: Ohio
Posts: 10,466
Quote:
Originally Posted by DeltaLover
I understand, reverse engineering Basic code especially written with a lot of GOTO is not a fun task.
That depends on your motivation. Solving a really complex puzzle can be quite stimulating.
Actor is offline   Reply With Quote Reply
Old 01-12-2017, 06:23 PM   #313
Actor
Librocubicularist
 
Join Date: Jun 2010
Location: Ohio
Posts: 10,466
Quote:
Originally Posted by traynor
I used it. It was a big time loser then, probably (would be) even more so now.
I've never had anyone else's code work straight out of the box. I've always had to tinker with it, usually to no avail. But it's fun.
Actor is offline   Reply With Quote Reply
Old 01-12-2017, 07:02 PM   #314
traynor
Registered User
 
traynor's Avatar
 
Join Date: Jan 2005
Posts: 6,626
https://www.rstudio.com/products/rstudio/download/

Free.

https://www.rstudio.com/products/rstudio/download/

Free.

https://mran.microsoft.com/download/

Free.

Time to learn all this stuff--available. Providing I use the time I have been wasting trying to get Linux Mint to stop crashing a half dozen times a day. It might LOOK like a well-designed GUI, but it is clearly a LONG way from being ready for prime-time. Possibly a step up for those who primarily use consoles. A big step down for those accustomed to Microsoft GUIs.
traynor is offline   Reply With Quote Reply
Old 01-12-2017, 07:05 PM   #315
traynor
Registered User
 
traynor's Avatar
 
Join Date: Jan 2005
Posts: 6,626
Quote:
Originally Posted by Actor
I've never had anyone else's code work straight out of the box. I've always had to tinker with it, usually to no avail. But it's fun.
Depends on what you paid for it. Buying software as a product, one tends to expect it to perform as claimed. Caveat emptor.
traynor is offline   Reply With Quote Reply
Reply





Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

» Advertisement
» Current Polls
Wh deserves to be the favorite? (last 4 figures)
Powered by vBadvanced CMPS v3.2.3

All times are GMT -4. The time now is 06:20 AM.


Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Copyright 1999 - 2023 -- PaceAdvantage.Com -- All Rights Reserved
We are a participant in the Amazon Services LLC Associates Program, an affiliate advertising program
designed to provide a means for us to earn fees by linking to Amazon.com and affiliated sites.