[SciPy-user] scipy code contribution question

Lev Givon lev@columbia....
Wed Jul 4 19:14:21 CDT 2007

Received from Ed Schofield on Wed, Jul 04, 2007 at 06:33:19PM EDT:
> On 7/4/07, Lev Givon <lev@columbia.edu> wrote:
> > I recently had occasion to translate one of the functions in Matlab's
> > signal processing toolkit not currently available in scipy into Python
> > for my own nefarious purposes (i.e., reworking some extant Matlab code
> > in Python). Might there be any copyright obstacles to my contributing
> > it to scipy? I personally suspect not because
> >
> > - Mathworks' copyright specifically protects its Matlab code and
> >   cannot constrain one from reimplementing non-patented and/or publicly
> >   available algorithms in other languages;
> > - my reimplementation is not an exact translation of said Matlab code;
> >   and
> > - the code of several scipy functions seems to have been directly
> >   inspired by that of corresponding functions included in Matlab.
> I think a translation of software into a different language would be
> considered a "derivative work":
> http://www.copyright.gov/circs/circ14.html
> http://ec.europa.eu/internal_market/copyright/documents/documents_en.htm
> This definition applies to a motion picture based on a play, so it
> would also cover a less-than-exact translation. If several scipy
> functions were "directly inspired by" functions from Matlab (or
> Numerical Recipes, or other sources), this would pose us no problem --
> but if there are any that look like they might be "derivative works",
> and therefore infringing, let us know so we can root them out. I think
> that we should err on the side of caution, with a zero-tolerance
> policy for contaminated code.
> Back to your original question, then: I'd suggest that you post some
> documentation here about what steps the code takes, using your
> judgment about how detailed to make it, and ask for a volunteer to
> write a clean-room implementation. Sorry that this requires more work,
> but I think it's important for the legitimacy of the project.
> -- Ed

Perhaps I am reading too deeply into the code, but it seems that a few
(but not all) of the scipy filter design functions (e.g., buttord,
cheb1ord) bear more than a passing similarity to their Matlab
counterparts insofar as their internal structure or logical flow are
concerned. (On the other hand, perhaps the published descriptions of
the filter design techniques in question are sufficiently explicit as
to lead to structural similarity in most independent implementations.)

Insofar as the item that prompted my first message, I desire a filter
design function similar to others currently available in scipy to
facilitate the construction of FIR filters with the Remez algorithm
(i.e., something similar to the remezord or firpmord functions in
Matlab) given some typical design parameters (e.g., band cutoff
frequencies, ripple constraints, etc.). As the relevant algorithms
needed by such a filter design function are not overly complicated, I
could look them up an appropriate DSP text or paper and try
implementing them completely from scratch (unless some generous soul
reading this list has already done so :-)


More information about the SciPy-user mailing list