Are neural nets (the weights file) copyrightable?

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

Moderators: hgm, Rebel, chrisw

Michel
Posts: 2272
Joined: Mon Sep 29, 2008 1:50 am

Re: Are neural nets (the weights file) copyrightable?

Post by Michel »

Dann Corbit wrote: Tue Mar 02, 2021 9:34 am
Michel wrote: Tue Mar 02, 2021 8:38 am
hgm wrote:I also suspect that (in the context of computer programs) there is something very wrong with the argument that the functionality is not copyrightable, only the 'creative freedom' on top of it.
Yes there seems to be something wrong with ignoring functionality.
  • The fact that a program is statically or dynamically linked makes zero difference for the functionality of the program. It is an implementation detail (and in addition, with the standard concept of linking, the actual memory copy of the program is virtually the same). If copyright law truly makes a difference between these (I am not convinced) then there is something very wrong with copyright law.
  • Likewise, whether a library is interpreted, byte compiled and then interpreted, just in time compiled, pre-compiled, or accessed by whatever scheme that is yet to be invented, is an implementation detail with no effect on functionality. It should make zero difference with respect to the context in which the library can be used.
There is something that feels wrong about all the effort that goes into making a phone book, and yet the phone book is not copyrightable.
But there is a method behind that madness.
Why should someone get exclusive rights to print a phonebook, when all that was involved was tedious, simple steps that anyone could accomplish?

There is something that feels wrong about not protecting an enormous effort spent creating special formulas to accelerate numerical integration.
The Japanese professors who invented double exponential integration spent years on it.
The guy in Utah who perfected sinc integration spent years on it.
But it makes sense to protect math.
Why should anyone own a math formula?
That math formula existed for eternity, until it was uncovered. And if the guy who uncovered it did not do it, someone else was going to uncover it shortly. That's why Newton and Leibnitz both invented calculus at the same time. The necessary preliminary steps had already been completed.

Copyright does not protect hard work. Copyright protects original thought. And that is how it should be.
IMO-YMMV
Your reply has nothing to do with my post. I have the feeling that you did not actually read my post before replying.

I sketched situations where there is zero difference with regard to original thought (and with regard to anything that matters actually) and yet it is argued by people here that they would be treated differently under copyright law. If that is so (and I do not know enough about copyright law to truly object) then there is something wrong with copyright law.

Needless to say I like to reason by analogy. This is a common practice in law. Similar situations should have similar outcomes.
Ideas=science. Simplification=engineering.
Without ideas there is nothing to simplify.
User avatar
hgm
Posts: 27810
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Are neural nets (the weights file) copyrightable?

Post by hgm »

But the concept of 'functionality' only plays a role in copyright law to determine whether a binary contains copyrightable material. A license agreement can require anything, even if it has no relation to copyrights at all. Like that one should pay a yearly amount for the right to distribute. So it can certainly stipulate that it is not allowed to distribute together with something that is statically linked to it, but can be distributed with something that is dynamically linked to it.

But to require anything at all, the material to be copied must of course be copyrightable. And I somehow doubt that modern compilers leave anything that could be called 'creative expression' of the programmer in the binary. All alpha-beta engines do basically the same thing even at source-code level. They might use different parameters for extensions and reductions, or different values in their PST. Or some might have original evaluation terms, recognizing patterns that other engines are blind too. But isn't that all functionality? The layout of the program, or the asserts will not affect the binary. Naming of the variables will not affect the binary. (Plus we already decided that this is 'non-essential' creative choice, and would not qualify for copyrights.)

Evaluation used to be the part where chess engines really differed. But when this task is performed by an NNUE, this difference (which could be argued to be functionality in the first place) also is reduced to just different parameter values. And tuning parameter values is "sweat of the brow" rather than "creative choice", so that doesn't qualify for copyrights.

So it seems NNUE engines cannot be considered 'original' in any way. Which would mean they are not copyrightable.
Michel
Posts: 2272
Joined: Mon Sep 29, 2008 1:50 am

Re: Are neural nets (the weights file) copyrightable?

Post by Michel »

But the concept of 'functionality' only plays a role in copyright law to determine whether a binary contains copyrightable material. A license agreement can require anything, even if it has no relation to copyrights at all. Like that one should pay a yearly amount for the right to distribute. So it can certainly stipulate that it is not allowed to distribute together with something that is statically linked to it, but can be distributed with something that is dynamically linked to it.
I understand. I originally thought this is what the GPL is doing. But the GPL (even the GPL-3) apparently does something different. It relies on copyright law to define a derived work (or rather something legally equivalent to it but not depending on American copyright law).

After that it puts restrictions on derived works. If you cannot meet these restrictions you lose the right to distribute the GPL'ed program on which the derived work is based, and by extension you cannot distribute the derived work itself.

This depends on the claim of the FSF that a dynamically linked program still constitutes a derived work (otherwise it would be trivial to hijack any GPL'ed program). Apparently many people claim that this interpretation by the FSF is not deducible from copyright law.

However a dynamically and a statically linked program are functionally entirely equivalent and the actual memory copy which is executed, which is all that matters ultimately, is virtually the same.

So if a statically and a dynamically linked program are indeed different under copyright law then this is very strange.
Last edited by Michel on Tue Mar 02, 2021 11:12 am, edited 2 times in total.
Ideas=science. Simplification=engineering.
Without ideas there is nothing to simplify.
User avatar
towforce
Posts: 11589
Joined: Thu Mar 09, 2006 12:57 am
Location: Birmingham UK

Re: Are neural nets (the weights file) copyrightable?

Post by towforce »

syzygy wrote: Tue Mar 02, 2021 2:31 amWhat a mess... You don't need the source code of a shared library that a GPL'd executable links to to "generate, install and run the object code and to modify the work".

Unless I've missed something, that looks clear and sensible to me. Just as an example, suppose I wrote a program that used a closed-source library to read XML and Json data, and this wasn't the focus of my program - just an incidental requirement. I could still GPL my program, but I wouldn't be able to GPL the closed-source library - even though it was an essential part of the bundle.

You don't need interpreted code to start an interpreter. (Nor do you need an NNUE net to start SF NNUE.) On the other hand, if you distribute an interpreter together with a program that can be interpreted by it, the combination is arguably an extended program that, in order to work, needs the interpreted code (which then apparently should be GPL'd).

I fundamentally disagree that SF is an interpreter and that a weights file is interpreted code, and I believe that a court would as well. Also, the GPL makes it clear that the interpreted code differentiation is allowed only when the functionality of the interpreted code is fundamentally different from the interpreter: in the case of SF, they are exactly the same: they exist to evaluate a chess position. End of discussion! :)
Writing is the antidote to confusion.
It's not "how smart you are", it's "how are you smart".
Your brain doesn't work the way you want, so train it!
User avatar
towforce
Posts: 11589
Joined: Thu Mar 09, 2006 12:57 am
Location: Birmingham UK

Re: Are neural nets (the weights file) copyrightable?

Post by towforce »

syzygy wrote: Tue Mar 02, 2021 1:48 amYes, it is has been my position from the start that an NNUE net is free of copyright. In my view this would even be the case if its values were all handcrafted, because an NNUE net is not a perceivable creative expression.

You are saying that a work of art can be copyrighted, but a template used to help produce that art cannot. That's probably wrong IMO.
Writing is the antidote to confusion.
It's not "how smart you are", it's "how are you smart".
Your brain doesn't work the way you want, so train it!
User avatar
towforce
Posts: 11589
Joined: Thu Mar 09, 2006 12:57 am
Location: Birmingham UK

Re: Are neural nets (the weights file) copyrightable?

Post by towforce »

syzygy wrote: Tue Mar 02, 2021 2:36 am
towforce wrote: Mon Mar 01, 2021 3:53 pm
hgm wrote: Mon Mar 01, 2021 3:42 pmWhy do you think I have any motivation one way or the other in making Stockfish derivatives?
I fully accept that, regarding the two main issues under dispute..

1. Can an NN be copyrighted?

2. Does SF's GPL license oblige CB to publish FF2's NN weights file?

..there are no precedents to my knowledge that have been decided in a court.

However, it seems to me that you're producing arguments in favour of (1) yes (2) no which are somewhat stretched and convoluted, implying that your heart lies in allowing bundling of new NNs with GPL software while holding the copyright on the NN.

I also claim impartiality, and my view is (1) yes (2) yes.
I often don't agree with HGM, but there is no doubt in my mind that he has no hidden agenda. I find it very disturbing to see someone being accused of having some "motivation" just because he is trying to objectively analyse the situation to the best of his abilities (whether I agree with his conclusions or not).

In the quoted text I said that there are no precedents, and hence the actual law isn't known. The issue is that HGM is using lines of argument that can fairly be described as "stretched" or "convoluted". My opinion is that if you asked software developers who had no knowledge of this dispute whether a set of NN weights is an interpreted language, most would say "no". If you then asked whether a chess program should be defined as an interpreter for a set of NN weights, even more would say "no".
Writing is the antidote to confusion.
It's not "how smart you are", it's "how are you smart".
Your brain doesn't work the way you want, so train it!
User avatar
hgm
Posts: 27810
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Are neural nets (the weights file) copyrightable?

Post by hgm »

Well, so you have an 'opinion', which as far as we know is not based on any actual fact. And because of that you suggest that someone who has another opinion must have a 'motivation', which is just a sneaky attempt to spread the idea that he must be intentionally lying.

Nice going. I can see the presence on 'the other forum' is already starting to rub off on you... :(
User avatar
towforce
Posts: 11589
Joined: Thu Mar 09, 2006 12:57 am
Location: Birmingham UK

Re: Are neural nets (the weights file) copyrightable?

Post by towforce »

hgm wrote: Tue Mar 02, 2021 11:18 am Well, so you have an 'opinion', which as far as we know is not based on any actual fact. And because of that you suggest that someone who has another opinion must have a 'motivation', which is just a sneaky attempt to spread the idea that he must be intentionally lying.

Straw man argument (link):

1. The reason I questioned your motivation is not because your POV is different to mine - it's because you are using lines of argument which in my opinion (and the opinion of others) are stretched

2. I have never suggested that you are lying

Nice going. I can see the presence on 'the other forum' is already starting to rub off on you... :(
Writing is the antidote to confusion.
It's not "how smart you are", it's "how are you smart".
Your brain doesn't work the way you want, so train it!
Dann Corbit
Posts: 12542
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

Re: Are neural nets (the weights file) copyrightable?

Post by Dann Corbit »

Michel wrote: Tue Mar 02, 2021 9:58 am
Dann Corbit wrote: Tue Mar 02, 2021 9:34 am
Michel wrote: Tue Mar 02, 2021 8:38 am
hgm wrote:I also suspect that (in the context of computer programs) there is something very wrong with the argument that the functionality is not copyrightable, only the 'creative freedom' on top of it.
Yes there seems to be something wrong with ignoring functionality.
  • The fact that a program is statically or dynamically linked makes zero difference for the functionality of the program. It is an implementation detail (and in addition, with the standard concept of linking, the actual memory copy of the program is virtually the same). If copyright law truly makes a difference between these (I am not convinced) then there is something very wrong with copyright law.
  • Likewise, whether a library is interpreted, byte compiled and then interpreted, just in time compiled, pre-compiled, or accessed by whatever scheme that is yet to be invented, is an implementation detail with no effect on functionality. It should make zero difference with respect to the context in which the library can be used.
There is something that feels wrong about all the effort that goes into making a phone book, and yet the phone book is not copyrightable.
But there is a method behind that madness.
Why should someone get exclusive rights to print a phonebook, when all that was involved was tedious, simple steps that anyone could accomplish?

There is something that feels wrong about not protecting an enormous effort spent creating special formulas to accelerate numerical integration.
The Japanese professors who invented double exponential integration spent years on it.
The guy in Utah who perfected sinc integration spent years on it.
But it makes sense to protect math.
Why should anyone own a math formula?
That math formula existed for eternity, until it was uncovered. And if the guy who uncovered it did not do it, someone else was going to uncover it shortly. That's why Newton and Leibnitz both invented calculus at the same time. The necessary preliminary steps had already been completed.

Copyright does not protect hard work. Copyright protects original thought. And that is how it should be.
IMO-YMMV
Your reply has nothing to do with my post. I have the feeling that you did not actually read my post before replying.

I sketched situations where there is zero difference with regard to original thought (and with regard to anything that matters actually) and yet it is argued by people here that they would be treated differently under copyright law. If that is so (and I do not know enough about copyright law to truly object) then there is something wrong with copyright law.

Needless to say I like to reason by analogy. This is a common practice in law. Similar situations should have similar outcomes.
The purpose of my post was to show that intuition is not a good way to analyze copyright law.
At first glance, things that seem intuitive turn out to be the wrong metaphor.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
User avatar
hgm
Posts: 27810
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Are neural nets (the weights file) copyrightable?

Post by hgm »

Michel wrote: Tue Mar 02, 2021 10:56 amI understand. I originally thought this is what the GPL is doing. But the GPL (even the GPL-3) apparently does something different. It relies on copyright law to define a derived work (or rather something legally equivalent to it but not depending on American copyright law).

After that it puts restrictions on derived works. If you cannot meet these restrictions you lose the right to distribute the GPL'ed program on which the derived work is based, and by extension you cannot distribute the derived work itself.

This depends on the claim of the FSF that a dynamically linked program still constitutes a derived work (otherwise it would be trivial to hijack any GPL'ed program). Apparently many people claim that this interpretation by the FSF is not deducible from copyright law.
They can define 'derived work' in any way they want, as long as they don't claim copyrights on it. They could define that it includes the house of the person who distributes, and require that the roof of that would have to be painted yellow first. As long as it is used only as terminology for specifying the conditions under which you can distribute the part they hold teh copyrights on, there isn't any restriction on how they could define it.

The only way copyright law comes into this is when determining whether they have the right to forbid you copying/distributing some part of it. Once they do, they can make arbitrary demands in return for waving that right.