Skip to content

clearsky.py requires scipy.io #13

Closed

Description

@wholmgren

Scipy either needs to be added to the setup.py file or we need to wrap the scipy statement with try/except and then throw a warning about reduced usability.

I would lean towards the latter as scipy installation is much more difficult than numpy and pandas. Best would be to remove the scipy.io dependency entirely.

Activity

  1. bmu commented on Mar 2, 2015

    @bmu
    Contributor

    Recent matlab files should be hdf5 based (see this question on SO). So maybe we could simply update this file and read it with pd.read_hdf (Seems not to work with the current file, so maybe this is created with an older matlab version).

  2. wholmgren commented on Mar 2, 2015

    @wholmgren
    MemberAuthor

    Looks like it's matlab 5.

    $ head pvlib/data/LinkeTurbidities.mat 
    MATLAB 5.0 MAT-file, Platform: PCWIN64, Created on: Mon Jul 16 10:16:10 2012
    

    I checked the PVLIB 1.2 release and it's the same. I think that the ideal situation would be for both the matlab and python projects to use the same .h5 file. Maybe this could be a part of the work going into #3.

  3. robwandrews commented on Mar 3, 2015

    @robwandrews
    Contributor

    Yes, I think the best would be for us to lead in translating this into a more portable file format, best case would be a .csv that can then be read with standard techniques (as this is just a 2D array). Any takers? In the near term, @wholmgren , could you add scipy.io to the setup.py to make sure we're internally consistent?

  4. wholmgren commented on Mar 3, 2015

    @wholmgren
    MemberAuthor

    Yes, but I would prefer to go with something like

    try: 
        import scipy.io
    except ImportError:
        raise(ImportError, 'You must install scipy to automatically load the Linke Turbidities')

    right before line 137.

  5. added this to the 0.1 milestone on Mar 12, 2015
  6. self-assigned this
    on Mar 12, 2015
  7. robwandrews commented on Mar 12, 2015

    @robwandrews
    Contributor

    Sounds good to me

  8. bmu commented on Mar 20, 2015

    @bmu
    Contributor

    I close this for 0.1 in favor of #36

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions