On Crafty...

Discussion of anything and everything relating to chess playing software and machines.

Moderator: Ras

bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: On Crafty...

Post by bob »

rbarreira wrote:
bob wrote: As far as your last question, yes it is perfectly correct, since the piece borrowed from Pradu is clearly indicated in that same source file, and anything Pradu writes is automatically copyrighted by him.
What I'm saying is that I did a grep for "Pradu" (case insensitive) on Crafty 23.4 and nothing was found. That's why I was wondering if his code wasn't used anymore.

Code: Select all

 *   21.3    "Magic" move generation is now used, which eliminates the rotated *
 *           bitboard approach completely.  Not a significant speed change,    *
 *           but it is far simpler overall.  Original code by Pradu Kannan as  *
 *           posted on CCC/Winboard forums, modified to work with Crafty.      
That is in the current code. The older code explicitly mentioned that "Magic" was included, but somewhere in shipping source back and forth, Pradu's name was left off. Someone pointed that out several months ago and I corrected it in the current source.

Code: Select all

 *   21.3    "Magic" move generation is now used, which eliminates the rotated *
 *           bitboard approach completely.  Not a significant speed change,    *
 *           but it is far simpler overall.   
Was the original comment...
bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: On Crafty...

Post by bob »

Dann Corbit wrote:
bob wrote:
Milos wrote:
bob wrote:Here's the problem, "there is NO public domain code in either program."
So it means you hold copyright on bubble sort in Crafty?
Interesting, I thought the very same implementation of bubble sort you copied verbatim from Knuth...
Clearly you are lying (since there is obviously quite a bit of PD code in Crafty), so why would anyone trust you when you make your usual baseless accusations?
I hold the copyright on _the_ bubble sort in crafty, yes. Not on the bubble sort idea, but on that specific code, along with everything else in there that I wrote. That was simple, wawsn't it. What PD code was in the Crafty that was copied into Fruit? Today's crafty certainly has Pradu's magic move generation code, attributed to him in the comments. The version copied and used in Rybka certainly did not. Please identify any PD code in Crafty, by specific source file name and line numbers, for the 19.0 version used as the basis for Rybka's bitboard code...

ball is in your court... You certainly ought to be able to go to "sorting and searching" by Knuth and cite the exact page where the code was copied "verbatim", correct? Actually, if you look carefully, Crafty uses _TWO_ different types of sorts, depending on whether it is a full-width node or a quiiece-only node. And the code looks nothing like the code you claim I copied "verbatim".

But, your turn...

BTW, you are now trying to justify your "Robolito/etc/Houdini is legal" on the real "stretch" that all Houdart copied into Houdini was the sort code from Crafty? Are you sure that code is in Robolito? :) Did you see my _explicit_ reference to the bitboard code (particularly the initialization) that is in Robolito?

We've done been down this road once in the Fruit / Rybka discussion. Same lame arguments Each was disproved, over time, by massive evidence. Houdini's day will come, too. Yuri has already commented on it. But don't let that disturb your thinking... Nor any of the other posts concerning Robo and Houdini. Hang on to that dream for as long as you can...
It can be safely said that Crafty's code is beyond reproach.
All contributed code is clearly documented. The historical commentary found in main.c is the example for all programmers to follow.

It would be a benefit to mankind if not just every computer chess program but every program in general were programmed and documented in this way.

As far as the implementation of bubble sort, it is also obvious that Dr. Hyatt has copyright on his own implementation. Failure to understand this is failure to understand what "copyright" means.

Yes, I am a Dr. Hyatt fan, I freely admit. However, that has nothing to do with my opinion on this matter.
Did you not write the "insertion sort" used in the main search (next.c) code a few years back? I think that is correct and that I put your name in the local comments rather than main.c for reasons unknown. Then the code was modified a bit and the comments in next.c were re-written to reflect the changes, and your name went missing somehow. If I am remembering this correctly, I'll fix the comments again...

If you recall, back then it came up over and over that a bubble sort was not the most efficient sort. I kept responding "yes, but I am sorting very few moves, just one or two most of the time and that plain bubble-sort is quite good there. I think you wrote the code and sent me the modified source as a way to "stop that question." :)
bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: On Crafty...

Post by bob »

bob wrote:
Milos wrote:
bob wrote:Here's the problem, "there is NO public domain code in either program."
So it means you hold copyright on bubble sort in Crafty?
Interesting, I thought the very same implementation of bubble sort you copied verbatim from Knuth...
Clearly you are lying (since there is obviously quite a bit of PD code in Crafty), so why would anyone trust you when you make your usual baseless accusations?
I hold the copyright on _the_ bubble sort in crafty, yes. Not on the bubble sort idea, but on that specific code, along with everything else in there that I wrote. That was simple, wawsn't it. What PD code was in the Crafty that was copied into Fruit? Today's crafty certainly has Pradu's magic move generation code, attributed to him in the comments. The version copied and used in Rybka certainly did not. Please identify any PD code in Crafty, by specific source file name and line numbers, for the 19.0 version used as the basis for Rybka's bitboard code...

ball is in your court... You certainly ought to be able to go to "sorting and searching" by Knuth and cite the exact page where the code was copied "verbatim", correct? Actually, if you look carefully, Crafty uses _TWO_ different types of sorts, depending on whether it is a full-width node or a quiiece-only node. And the code looks nothing like the code you claim I copied "verbatim".

But, your turn...

BTW, you are now trying to justify your "Robolito/etc/Houdini is legal" on the real "stretch" that all Houdart copied into Houdini was the sort code from Crafty? Are you sure that code is in Robolito? :) Did you see my _explicit_ reference to the bitboard code (particularly the initialization) that is in Robolito?

We've done been down this road once in the Fruit / Rybka discussion. Same lame arguments Each was disproved, over time, by massive evidence. Houdini's day will come, too. Yuri has already commented on it. But don't let that disturb your thinking... Nor any of the other posts concerning Robo and Houdini. Hang on to that dream for as long as you can...
The comment by Milos is stupid. When I get down to my office, I will "verbatim copy" Knuth's bubble sort code and post it here. I will then "verbatim copy" each sort inside Crafty into the same post. Then someone can decide if there is a "verbatim copy" of Knuth's bubble sort or not.

Some of the statements he makes are beyond belief. Until you have read enough of his posts, then nothing is beyond belief.
User avatar
michiguel
Posts: 6401
Joined: Thu Mar 09, 2006 8:30 pm
Location: Chicago, Illinois, USA

Re: On Crafty...

Post by michiguel »

Dann Corbit wrote:
bob wrote:
Milos wrote:
bob wrote:Here's the problem, "there is NO public domain code in either program."
So it means you hold copyright on bubble sort in Crafty?
Interesting, I thought the very same implementation of bubble sort you copied verbatim from Knuth...
Clearly you are lying (since there is obviously quite a bit of PD code in Crafty), so why would anyone trust you when you make your usual baseless accusations?
I hold the copyright on _the_ bubble sort in crafty, yes. Not on the bubble sort idea, but on that specific code, along with everything else in there that I wrote. That was simple, wawsn't it. What PD code was in the Crafty that was copied into Fruit? Today's crafty certainly has Pradu's magic move generation code, attributed to him in the comments. The version copied and used in Rybka certainly did not. Please identify any PD code in Crafty, by specific source file name and line numbers, for the 19.0 version used as the basis for Rybka's bitboard code...

ball is in your court... You certainly ought to be able to go to "sorting and searching" by Knuth and cite the exact page where the code was copied "verbatim", correct? Actually, if you look carefully, Crafty uses _TWO_ different types of sorts, depending on whether it is a full-width node or a quiiece-only node. And the code looks nothing like the code you claim I copied "verbatim".

But, your turn...

BTW, you are now trying to justify your "Robolito/etc/Houdini is legal" on the real "stretch" that all Houdart copied into Houdini was the sort code from Crafty? Are you sure that code is in Robolito? :) Did you see my _explicit_ reference to the bitboard code (particularly the initialization) that is in Robolito?

We've done been down this road once in the Fruit / Rybka discussion. Same lame arguments Each was disproved, over time, by massive evidence. Houdini's day will come, too. Yuri has already commented on it. But don't let that disturb your thinking... Nor any of the other posts concerning Robo and Houdini. Hang on to that dream for as long as you can...
It can be safely said that Crafty's code is beyond reproach.
All contributed code is clearly documented. The historical commentary found in main.c is the example for all programmers to follow.

It would be a benefit to mankind if not just every computer chess program but every program in general were programmed and documented in this way.

As far as the implementation of bubble sort, it is also obvious that Dr. Hyatt has copyright on his own implementation. Failure to understand this is failure to understand what "copyright" means.

Yes, I am a Dr. Hyatt fan, I freely admit. However, that has nothing to do with my opinion on this matter.
The shocking fact is that someone is using bubble sort :-)
Is Crafty using bubble sort or this is one the gazillion Byzantine discussions we see in CCC?
I bet the latter.

Miguel
tomgdrums
Posts: 736
Joined: Wed Dec 02, 2009 9:48 am

Re: On Crafty...

Post by tomgdrums »

Roger Brown wrote:Dear All,

Milos has made what I consider to be some serious statements about Crafty and by extension, Dr. Robert Hyatt.

As the thread containing his statement was locked I thought it only fair that this part be split off and he respond by outlining the basis of the facts he asserted previously.

The original thread may of course be examined to ensure that his words have been copied as written.

Over to you Milos....

Later.
Well done Roger!

Milos has been strangely silent since you called him out.
Milos
Posts: 4190
Joined: Wed Nov 25, 2009 1:47 am

Re: On Crafty...

Post by Milos »

bob wrote:I hold the copyright on _the_ bubble sort in crafty, yes. Not on the bubble sort idea, but on that specific code, along with everything else in there that I wrote.

ball is in your court... You certainly ought to be able to go to "sorting and searching" by Knuth and cite the exact page where the code was copied "verbatim", correct? Actually, if you look carefully, Crafty uses _TWO_ different types of sorts, depending on whether it is a full-width node or a quiiece-only node. And the code looks nothing like the code you claim I copied "verbatim".
My, my, a lot of ppl here seams to be afraid of "big" authority, but it's really time to show them the "emperor is naked".
So let's see your "copyrighted" bubble sort code (lol for using it, believe it or not Miguel he is really using it, as Knuth (the real authority not a fake one like you) says: "In short, the bubble sort seems to have nothing to recommend it, except a catchy name and the fact that it leads to some interesting theoretical problems.")
From Crafty 23.4, root.c 135-148 and quiesce.c 162-176:

Code: Select all

  do {
    done = 1;
    for (i = 0; i < lastm - rmoves - 1; i++) {
      if (sort_value[i] < sort_value[i + 1]) {
        temp = sort_value[i];
        sort_value[i] = sort_value[i + 1];
        sort_value[i + 1] = temp;
        temp = rmoves[i];
        rmoves[i] = rmoves[i + 1];
        rmoves[i + 1] = temp;
        done = 0;
      }
    }
  } while (!done);

Code: Select all

    do {
      done = 1;
      sortv = tree->sort_value;
      for (movep = tree->last[ply - 1]; movep < tree->last[ply] - 1;
          movep++, sortv++)
        if (*sortv < *(sortv + 1)) {
          temp = *sortv;
          *sortv = *(sortv + 1);
          *(sortv + 1) = temp;
          temp = *movep;
          *movep = *(movep + 1);
          *(movep + 1) = temp;
          done = 0;
        }
    } while (!done);
That much about two different types of sorts. You don't even know your own code. Both textbook bubble sort.
Now regarding Knuth, in his The Art of Computer Programming - Volume 3 - Sorting and Searching, 2nd ed. page 107 there is a code which is in his pseudo machine language. The code is identical to yours except variable names, his "done" is called "t" and has initial value of 0 and if there was a swap than it gets value 1. The format is the same "do..while" meaning the same post-test loop type. The minimal difference is in comparison since his sorting is in raising order, your in falling, but that's a trivial difference. Now, I really don't intend to type it from the paper book. Anyone, who is at least a bit of programmer has the book on its shelf and can check what I'm talking about. Instead here is the same implementation in little bit more recognizable fashion (for those who are not so experienced with programming :))

Wikipedia on bubble sort:

Code: Select all

  do
    swapped = false
    for each i in 1 to length(A) - 1 inclusive do:
      if A[i-1] > A[i] then
        swap( A[i-1], A[i] )
        swapped = true
      end if
    end for
  while swapped
Looks familiar doesn't it??? :)
So when are you planning to sue wikipedia for stealing your copyrighted code, since a haven't seen a single reference of you on that page, ha? ;)
Oh, yes, you have a swap implementation, they don't so that one must be copyrightable then, right? :lol:
What PD code was in the Crafty that was copied into Fruit? Today's crafty certainly has Pradu's magic move generation code, attributed to him in the comments. The version copied and used in Rybka certainly did not. Please identify any PD code in Crafty, by specific source file name and line numbers, for the 19.0 version used as the basis for Rybka's bitboard code...
Completely irrelevant. The point is, you do use PD CODE in your Crafty (as I've just proven) and your attempt to claim it as your copyright is just pure BS despite what any apple-polisher here says.
Did you see my _explicit_ reference to the bitboard code (particularly the initialization) that is in Robolito?
Of course I did, that's why I called yours writing here a slander referring to yours "hundreds of lines of verbatim copied code".
So lets see, rotation tables are the same, but sorry there they are not copyrightable, good try, more luck next time ;).
Initialization of piece attack tables:
-pawn attacks - different
-knight attacks - same, but that's more than trivial, even more trivial than "your" bubble sort implementation
-rook attacks - different
-bishop attacks - different

So could you please show us these "hundreds of verbatim copied lines" referring to line numbers in your Crafty 19.0 and Robbo (pick up a version that you like)? Otherwise your writing is nothing more than slander.
The ball is in your court, professor...
Last edited by Milos on Tue May 24, 2011 1:47 am, edited 1 time in total.
Roger Brown
Posts: 782
Joined: Wed Mar 08, 2006 9:22 pm

Re: On Crafty...

Post by Roger Brown »

Hello Milos,

Below I am copying your statements:
So it means you hold copyright on bubble sort in Crafty?
Interesting, I thought the very same implementation of bubble sort you copied verbatim from Knuth...
Clearly you are lying (since there is obviously quite a bit of PD code in Crafty), so why would anyone trust you when you make your usual baseless accusations?
(1) Where is the evidence of the verbatim copying from Knuth?

(2) Where is the quite a bit of PD code in Crafty? A list will do, I take your abilities to identify and write code as a given for this purpose.....

(3) What lie are you accusing Dr. Hyatt of precisely?

Later.
Milos
Posts: 4190
Joined: Wed Nov 25, 2009 1:47 am

Re: On Crafty...

Post by Milos »

Roger Brown wrote:Hello Milos,

Below I am copying your statements:
So it means you hold copyright on bubble sort in Crafty?
Interesting, I thought the very same implementation of bubble sort you copied verbatim from Knuth...
Clearly you are lying (since there is obviously quite a bit of PD code in Crafty), so why would anyone trust you when you make your usual baseless accusations?
(1) Where is the evidence of the verbatim copying from Knuth?
You have all the references you need only if you are able to read...
(2) Where is the quite a bit of PD code in Crafty? A list will do, I take your abilities to identify and write code as a given for this purpose.....
Even one instance is enough to prove that Hyatt used PD code in Crafty, since he was categorically stating that there is no PD code in Crafty at all.
(3) What lie are you accusing Dr. Hyatt of precisely?
At least try to read my previous post instead of being prejudiced...
Roger Brown
Posts: 782
Joined: Wed Mar 08, 2006 9:22 pm

Re: On Crafty...

Post by Roger Brown »

Milos wrote:
You have all the references you need only if you are able to read...
Even one instance is enough to prove that Hyatt used PD code in Crafty, since he was categorically stating that there is no PD code in Crafty at all.
At least try to read my previous post instead of being prejudiced...

Hello Milos,

I am not totally surprised but it is disappointing when someone of your obvious abilities and intelligence resorts to arrogance, sneering and childish put downs, particularly when you know better.

Let me categorically state that you are my superior in every way related to computerchess. Compared to you I am a bumbling idiot. Let that be a given. I have no issues at all in acknowledging another my better, none at all, and I am quite willing to bow low before you if that is required.

I am asking you the questions precisely because you seem to have the answers. Sneering does not answer the questions.

I asked you to show the evidence of the verbatim copying. It would have been much easier to show the side by side comparisons to help fools like me see your point clearly but no, Milos must make the point of trampling even an ignoramus like me in the dust. What could be the point of that?

You claimed that there was quite a bit of PD code in Crafty. Now you are saying that even one example makes the point that there is quite a bit of it? Alright then....

Finally Milos, prejudiced? Please! I have said in public and in private to you that your intellectual gifts are clear to see and that they indicated a background in mathematics, statistics and computer science. Or is that already forgotten by you in the heat of this particular discussion?

I specifically opened this thread to afford you the opportunity to spell out the basis for your factual comments. Does that seem consistent with your comments about my possible motives or attitude?

Do not go looking for enemies Milos, some of us are really seeking knowledge and not seeking foes.

As usual though, I suspect that you will believe only in the correctness of your perceptions and not the facts before you.

Later.
Milos
Posts: 4190
Joined: Wed Nov 25, 2009 1:47 am

Re: On Crafty...

Post by Milos »

Roger Brown wrote:I am not totally surprised but it is disappointing when someone of your obvious abilities and intelligence resorts to arrogance, sneering and childish put downs, particularly when you know better.

Let me categorically state that you are my superior in every way related to computerchess. Compared to you I am a bumbling idiot. Let that be a given. I have no issues at all in acknowledging another my better, none at all, and I am quite willing to bow low before you if that is required.
I neither seek for any recognition nor I think you are idiot or layman. I just had a very strong impression you didn't read my post at all.
I am asking you the questions precisely because you seem to have the answers. Sneering does not answer the questions.

I asked you to show the evidence of the verbatim copying. It would have been much easier to show the side by side comparisons to help fools like me see your point clearly but no, Milos must make the point of trampling even an ignoramus like me in the dust. What could be the point of that?
Side by side comparison for ppl who are not computer programmers is worth only when 2 pieces of code are written in the same programming language (of the same level of complexity). As I already stated up there, Knuth gives his code in pseudo assembler language. The code is functionally equivalent to Hyatt's C code (not just equivalence of idea, but equivalence of implementation). The differences I've already pointed out, and they are at the level of triviality such as variable name change. I gave you the reference where you can find the code and I really don't intend to type it down from the book. Instead I gave more visually appealing (but again functionally same) code from wikipedia.
The same is valid for any of ICGA panel claims about Rybka/Crafty or Rybka/Fruit connection. Since Rybka is disassembled you would not find a single piece of code where just by visual inspection you can deduce equality unless you understand the assembler. So my question is, why are you asking detailed comparison from me, but under very same conditions you've never asked anything similar from Hyatt???
As usual though, I suspect that you will believe only in the correctness of your perceptions and not the facts before you.
Sorry but this is a direct proof of biased approach. You would never make the similar kind of "suspection" for the other side of discussion...

Even though you are acting in the best will and with best intentions seams sometimes you are totally unaware of the bias most of the ppl have towards authority...
Last edited by Milos on Tue May 24, 2011 3:39 am, edited 1 time in total.