problem with load()

32 views
Skip to first unread message

Eric Leroy

unread,
Dec 5, 2012, 10:02:08 AM12/5/12
to hypersp...@googlegroups.com
Hi,

I installed a fresh version of both EPD 7.3-2 and hyperspy 0.5.1 on my 64 bits windows 7 machine. When I want to load a file with the command s=load() I have the following error message :

In [1]: s=load()
---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)
C:\Users\pctomo\<ipython-input-1-14a3276894b3> in <module>()
----> 1 s=load()

C:\Python27\lib\site-packages\hyperspy\io.py in load(filenames, record_by, signa
l_type, stack, mmap, mmap_dir, **kwds)
    154                 filenames = load_ui.filename
    155         else:
--> 156             raise ValueError("No file provided to reader and "
    157             "interactive mode is disabled")
    158         if filenames is None:

ValueError: No file provided to reader and interactive mode is disabled

Do you have any idea of the problem? If I specify the filemane in the load command everything goes well.

Best regards

Eric

Francisco de la Peña

unread,
Dec 5, 2012, 10:15:36 AM12/5/12
to hypersp...@googlegroups.com
Hi,

Thank you for reporting this issue. The problem seems to be that hyperspy is not running in interactive mode. To enable the interactive mode execute preference.gui() and in the "General" tab tick the "interactive" box. Alternatively (and more conveniently) you can activate it executing the following command:

preferences.General.interactive = True

Could you let us know if this solves the issue?

Francisco


2012/12/5 Eric Leroy <ricou...@gmail.com>

Eric Leroy

unread,
Dec 7, 2012, 4:13:37 AM12/7/12
to hypersp...@googlegroups.com
Hi,

Thank you, it worked ! Is this setting permanent now or should I type it a every launch?

Best regards

Eric

Francisco de la Peña

unread,
Dec 7, 2012, 5:41:07 AM12/7/12
to hypersp...@googlegroups.com
Hi,

When using the UI the preferences are automatically saved in the hyperspyrc file and will be loaded the next time that you run hyperspy. When using the command line you must call execute preferences.save() to save the changes to the file.

Best wishes,

Francisco

2012/12/7 Eric Leroy <ricou...@gmail.com>
Reply all
Reply to author
Forward
0 new messages