A short lecture on Open Licensing

2017-01-04T14:53:31Z (GMT) by Lorena A. Barba
<div>Also on <a href="https://speakerdeck.com/labarba/a-short-lecture-on-open-licensing">SpeakerDeck</a>, for nicer viewing.</div><div><br></div>A lecture as part of the workshop <a href="https://barbagroup.github.io/essential_skills_RRC/">"Essential skills for reproducible research computing,"</a> at Universidad Técnica Federico Santa María (January 2017).<div><br></div><div>[slide 3]</div><div>Syllabus of the workshop.</div><div><br></div><div>[slide 5]</div><div><div>In an October-2015 <a href="http://rtalbert.org/blog/2015/interview-lorena-barba">interview</a> by mathematics professor and blogger Robert Talbert, I answer this question … “Why do you advocate so strongly for open-source technology in research and education?” … I start by first clarifying WHAT WE MEAN by “open.” </div></div><div><br></div><div>[slide 6]</div><div><div>"Free and open-source software (FOSS) is a human invention of tremendous impact. It poses an alternative to intellectual-property instruments that are limiting and want to control how a creative work is used. </div><div>Open-source licenses allow people to coordinate their work freely, within the confines of copyright law, while making access and wide distribution a priority. </div><div>I’ve always thought that this is fundamentally aligned with the method of science, where we value academic freedom and wide dissemination of scientific findings. […] </div><div><br></div><div>[slide 7]</div><div><div>Open licensing gives us freedom—contrary to intellectual-property instruments that want to control how creative works are used.</div><div>Freedom is power. In this case, the power of open-source software comes not just from being able to read the source code, but from being able to contribute to and build from it. </div><div>For this power to be realized, it's not sufficient to make the source public to read. We must attach a license that allows others to modify and distribute the code.</div></div><div><br></div><div>[slide 9]</div></div><div><div>So let’s be clear about this: </div><div>“Open data and content can be freely used, modified, and shared by anyone for any purpose.” (<a href="http://opendefinition.org">The Open Definition</a>)</div></div><div><br></div><div>[slide 12]</div><div><div>Stanford professor David Donoho and co-workers appear to be the first ones to publicly state that reproducibility depends on open code and data.</div><div>They define reproducible computational research as that "in which all details of computations—code and data—are made conveniently available to others." </div><div>They took inspiration from geophysics professor Jon Claerbout, who said that in computational science "the actual scholarship is the complete software development environment and the complete set of instructions which generated the figures."</div><div><br></div><div>Donoho, D.L. ; Maleki, A. ; Rahman, I.U. ; Shahram, M. ; Stodden, V. </div><div>Volume 11 Issue 1 (2009):8–18 </div><div>http://dx.doi.org/10.1109/MCSE.2009.15</div><div><br></div><div>[slide 13]</div><div>Everyone developing software in an academic setting should have working knowledge of software licenses. </div><div><br></div><div>[slide 14]</div><div>Screenshot of</div><div><div>Morin, A., J. Urban and P. Sliz (2012) A Quick Guide to Software Licensing for the Scientist-Programmer, PLoS Comput. Biol. 8(7): e1002598 </div><div>http://dx.doi.org/10.1371/journal.pcbi.1002598</div></div><div><br></div><div>[slide 15]</div></div><div><div>The first thing to understand is that simply making the source code public does not make your project open source. </div><div>Software is a creative work, and copyright is automatically attached to it. </div><div>Without a license, your software is in a legal limbo where readers don't know how they can use it, if at all: a well-informed reader will opt for not using your software, as the only safe behavior. </div><div>The license is a contract between the authors of software and the users. It gives software authors the power to share with users, and to collaborate with other developers.</div></div><div><br></div><div>[slide 16]</div><div>Always add a license to software you plan to make public.</div><div><br></div><div>[slide 17]</div><div><div>Free and open-source software is under a license that grants the users freedom: to access, use or modify the software for their purposes. </div><div>The most important distinction between the various FOSS licenses is whether they are permissive versus copyleft. These terms are often confused.</div></div><div><br></div><div>[slide 18]</div><div>A permissive license gives more freedoms: the only restriction of use could be that the original authors receive credit in any distribution of the software or any derivative works. Even commercial uses, or incorporating the software into other proprietary (closed) works, is allowed. Academic software benefit most from permissive licensing. In fact, permissive licenses originated at accademic institutions, including the Berkeley Software Distribution or BSD License, the MIT License and the Apache License.</div><div><br></div><div>[slide 19]</div><div>http://choosealicense.com/licenses/mit/</div><div><br></div><div>[slide 20]</div><div>A copyleft license restricts the use of the software by requiring that any derivative works be also under the license of the original. Another word for this model is "share-alike." Many developers want to ensure open access to their work and all derivatives for all posterity. This may be considered virtuous in some circles, but we should recognize that it is achieved by placing restrictions on the use of software. The typical copyleft license is GPL.</div><div><br></div><div>[slide 21]</div><div>http://choosealicense.com/licenses/gpl-3.0/</div><div><br></div><div>[slide 22]</div><div><div>License compatibility</div><div>Compatible licenses allow source code from different works to be combined to make new software. Not all licenses are compatible!</div></div><div>Because incompatible terms can arise from subtle wording, the Open Source Initiative (OSI) strongly recommends using an existing OSI-approved license, instead of attempting to craft a custom license. </div><div><br></div><div>[slide 23]</div><div><div>Note that compatibility is directional: it behaves differently whether a piece of code is built into or from another. (See the illustration below from Morin et al.) </div><div>Staff at university or laboratory technology offices may be ignorant of these issues, making it even more important for researchers to be well informed.</div><div>Figure 2 of Morin et al. (2012). Illustrates compatibility of licenses: permissive licenses (BSD, MIT) are forward-compatible with any other license, whereas copyleft licenses are only forward-compatible with themselves.</div><div>Directional compatibility of licenses is the reason why you should always be aware of the licensing terms of any code that you are reading and hoping to build upon.</div><div><br></div></div><div>[slide 24]</div><div>For academic and research software, you are likely to want a simple license that is most permissive. For example, you can use the MIT License. Most of the research code in our group has been released under MIT.</div><div><br></div><div>[slide 25]</div><div><div>Illustrating how subtle language variations matter, we recently decided to change our pick to the BSD 3-clause License. It is very similar to the MIT License, but there is a small difference in the wording about attribution …</div><div><br></div><div>This language implies that a user could copy some of an MIT-licensed code (as long as the portion is deemed "not substantial") without attribution. In academia, we always prefer full attribution of any portions of copied works, and BSD 3-clause is more precise in this.</div></div><div><br></div><div>[slide 26]</div><div>Bonus advice:</div><div><div>Write into your grant proposals that your research software will be released under an OSI-approved license. If you're lucky to have your grant funded, the condition of open-source code release becomes part of the contract with the university. </div><div><br></div><div>This can save you some grief when trying to explain to staff at the tech office why your software needs to be open source. They often just don't understand the field, and want to default to a proprietary license, imagining some commercial value may exist in your research code.</div></div><div><br></div>