[Ifeffit] Larch import error

Patridge, Christopher patridgc at dyc.edu
Tue Sep 10 06:51:43 CDT 2019


Good morning,

I have OSX Larch installed and attempting to open XAS data files.  It cannot read the file and Larch returns an error:

Error trying to read '/Users/DrPatridge/Desktop/2019-03-21/CaVO_50-40-10_vs_Zn.002':

    _tmp_file_ = read_xdi('/Users/DrPatridge/Desktop/2019-03-21/CaVO_50-40-10_vs_Zn.002')
             ^^^
   File /Users/DrPatridge/.larch/init.lar, line 1
  File "/xraylarch/share/larch/plugins/io/xdi.py", line 258, in read_xdi
    xdif = XDIFile(filename, labels=labels)
  File "/xraylarch/share/larch/plugins/io/xdi.py", line 124, in __init__
    self.read(self.filename)
  File "/xraylarch/share/larch/plugins/io/xdi.py", line 165, in read
    mvals = tostrlist(xdi.meta_values,   self.nmetadata)
  File "/xraylarch/share/larch/plugins/io/xdi.py", line 65, in Py3tostrlist
    return [str(i, 'ASCII') for i in (nitems*c_char_p).from_address(address)]
  File "/xraylarch/share/larch/plugins/io/xdi.py", line 65, in <listcomp>
    return [str(i, 'ASCII') for i in (nitems*c_char_p).from_address(address)]

UnicodeDecodeError: ('ascii', b'3.1356369 \xc3\x85', 10, 11, 'ordinal not in range(128)’)

Is this a plugin error or something else?  I attached one of the files if anyone could test?  I can open it in Athena.

Thanks for any help,

Chris

**********************************************
Dr Christopher Patridge
Associate Professor
Dept of Chemistry
SASE 315
716-829-8096 | patridgc at dyc.edu<mailto:patridgc at dyc.edu>
www.dyc.edu<http://www.dyc.edu>

Social: Twitter<http://www.twitter.com/drpatridgc>

[cid:0a129c79-2c47-40b9-8a0d-22bf08b7005d at namprd14.prod.outlook.com]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://millenia.cars.aps.anl.gov/pipermail/ifeffit/attachments/20190910/da3a9954/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: logo-web-redsmaller.png
Type: image/png
Size: 7850 bytes
Desc: logo-web-redsmaller.png
URL: <http://millenia.cars.aps.anl.gov/pipermail/ifeffit/attachments/20190910/da3a9954/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: CaVO_50-40-10_vs_Zn.001
Type: application/octet-stream
Size: 82686 bytes
Desc: CaVO_50-40-10_vs_Zn.001
URL: <http://millenia.cars.aps.anl.gov/pipermail/ifeffit/attachments/20190910/da3a9954/attachment-0001.obj>


More information about the Ifeffit mailing list