[SciPy-Dev] new tests in sparse

Blake Griffith blake.a.griffith@gmail....
Mon Jun 3 11:04:22 CDT 2013


On Mon, Jun 3, 2013 at 1:20 AM, Ralf Gommers <ralf.gommers@gmail.com> wrote:

>
> On Mon, Jun 3, 2013 at 1:32 AM, Blake Griffith <blake.a.griffith@gmail.com
> > wrote:
>
>> On Sun, Jun 2, 2013 at 3:02 PM, Ralf Gommers <ralf.gommers@gmail.com>wrote:
>>
>>>
>>> On Fri, May 31, 2013 at 11:49 PM, Blake Griffith <
>>> blake.a.griffith@gmail.com> wrote:
>>>
>>>> Hello scipy,
>>>> I'm in the process of adding new tests for sparse matrices with
>>>> dtype=bool, while I'm at it, I thought it would be a good idea to add tests
>>>> for other dtypes. Currently all the tests are for int64 and float64.
>>>>
>>>> There is some canonical data defined in test_base.py. I use this to
>>>> make data with all the supported dtypes. Then I change the tests that use
>>>> this canonical data to iterate over this data with different dtypes
>>>> (including bool).
>>>>
>>>> Does this sound ok? It will make running test_base.py a bit slower. You
>>>> can see my work here:
>>>>
>>>
>>> That makes sense to me. Depends on what you mean by "a bit" if it's a
>>> problem that tests run slower. If the test adds more than a few hundred
>>> milliseconds then you should think about what part of those tests have to
>>> be labeled @slow.
>>>
>>> Ralf
>>>
>>
>> I've been going through on a per test basis changing each test to test
>> every dtype instead of just one, so each modified test takes ~14 times as
>> long (14 for each supported dtype)... I think this will slow the test suite
>> way too much.
>>
>
> Right now test_base.py already takes ~7% of the time of scipy.test(), so
> 14x increase of that file is too much. Maybe there's something that can be
> done to make it run faster to start with. I'll try to have a look at what
> you changed so far tonight.
>
> Ralf
>
>
>
>> Unfortunately, the way I am adding theses tests using @slow would prevent
>> the whole test from being run. Ideally I would just decorate the new extra
>> dtype tests with @slow and the test would still run for the standard
>> int64/float64 dtypes. So I need to change the way I am doing this.
>>
>
I think rewriting this test suite, with paramterized dtypes and data would
be worth the effort I have a week before I start the next part of my GSoC
timeline which I think is enough time. It also will make my life easier for
the rest of the summer.

Does this sound too ambitious to do in a week?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/scipy-dev/attachments/20130603/80735631/attachment.html 


More information about the SciPy-Dev mailing list