Re: [Ifeffit] Athena: Data cannot be imported by using plugin PFBL12C
I have to admit I find this all sort of disappointing. First, the PFBL12C is a really poor way to represent EXAFS data. It uses a hard-to-parse and hard-to-interpret format and has many unlabeled columns. It appears to include this really odd notion that recording "angle" is somehow better than recording energy, and saves a ridiculuously over-sampled spectrum that needs smoothing because of the high noise per recorded point. It is, in short, a really poor way to represent EXAFS data. We've seen it for many years, we've written papers and published supported code for better representations of EXAFS data. Still, we get questions about using data recorded in such files. Data files this complex need a way to convert them into something useful. Second, the limitations you are seeing are due to using the outdated, no-longer-supported (for several years now actually) Ifeffit library. These data can be read and processed without problem with Larch, the replacement for Ifeffit. Stop using Ifeffit. Use Larch instead. Really. An example script to use larch for your `fail.dat` file is listed below. It is somewhat complicated because the raw data file is such a poor representation of EXAFS data. --Matt # larch script to read, smooth and process data in the horrible PFBL12C format # read raw data, extract angle, i0, sum of fluorescence datafile = 'fail.dat' rawdat = read_ascii(datafile) def degrees2eV(angle, dspace=1.63747): from scipy.constants import hbar, c, e hbarc = 1.e10*hbar*c/e return (pi*hbarc/dspace) / sin(angle*pi/180.0) #enddef rawdat.angle = rawdat.data[0, :] # angle in degrees. yikes! rawdat.energy = degrees2eV(rawdat.angle) rawdat.i0 = rawdat.data[42, :] rawdat.fluor = rawdat.data[3:42, :].sum(axis=0) # smooth data with Savitzky-Golay (data is ~evenly sampled in angle) smoothed = group(energy=rawdat.energy) smoothed.i0= savitzky_golay(rawdat.i0,5, 1) smoothed.fluor = savitzky_golay(rawdat.fluor, 5, 1) newplot(smoothed.energy, rawdat.fluor, win=3) plot(smoothed.energy, smoothed.fluor, zorder=50, linewidth=4, win=3) ### create "normal" XAFS energies, finely spaced over edge, ### but spaced evenly in k for the EXAFS e0= 8980.0 # nominal Cu K edge emin = smoothed.energy.min() emax = smoothed.energy.max() - 5.0 epre1 = e0 - 20.0 epre2 = e0 + 20.0 kmin = etok(20.0) kmax = etok(emax-e0) def make_range(start, stop, step): npts = max(2, 1 + int(0.1 + abs(stop-start)/abs(step))) return linspace(start, stop, npts) #enddef en_new = concatenate((make_range(emin, epre1, 5), make_range(epre1+0.5, epre2-0.5, 0.5), e0 + ktoe(make_range(kmin, kmax, 0.05 # now interpolate smoothed data onto this energy grid dat = group(energy=en_new, filename=datafile) dat.i0= interp(smoothed.energy, smoothed.i0,dat.energy) dat.fluor = interp(smoothed.energy, smoothed.fluor, dat.energy) dat.mu= dat.fluor / dat.i0 # run autobk autobk(dat, rbkg=0.8, kweight=1) # plot data plot_mu(dat, show_norm=True) plot_chik(dat, kweight=1, win=2) ### ___ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit
Re: [Ifeffit] Athena: Data cannot be imported by using plugin PFBL12C
Hi Yuri, You are probably running into the memory limit. This has been discussed a number of times on this mailing list, e.g.: https://www.mail-archive.com/ifeffit@millenia.cars.aps.anl.gov/msg03931.html https://www.mail-archive.com/ifeffit@millenia.cars.aps.anl.gov/msg05673.html Bruce's answer in the 2nd link provides some suggestions. Note, if I delete 1500 rows or so from your fail file, I am able to import it. This seems to be similar to the success.dat file which also appears to be truncated. Using a column labelled '20' as Io seems to work -R. On 11/14/2017 12:59 AM, 平岡 裕治 wrote: Dear all, I tried to import a data of multi-element detector at SPring-8 by using plugin PFBL12C to Athena, but it was not successful. if the number of rows in the file is about 2000[success.dat], it can be successfully imported. But for the data over about 4000 rows[fail.dat], it seems that several data at first of both converted energy and intensity are substituted by 0. column6.png shows intensity of ch6 vs energy_attained and I0.png shows intensity of I0 vs energy_attained. you can see this behavior. As a result, intensity cannot divide by I0, and data cannot be imported. if someone knows approach to solve this, could you teach me. Best regards, Yuji Hiraoka ___ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit ___ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit
Re: [Ifeffit] current-amp recommendation
HI Matthew: One possibility is the Caen quad amplifier that they made for BPMs. http://www.caenels.com/products/tetramm/ Carlo On Tue, 14 Nov 2017, Matthew Marcus wrote: I've gotten involved with a project in which stabilization of the position of a monochromatic, soft X-ray beam is needed. The offending frequencies seem to be vibration frequencies like 57 and 116Hz. We have in mind to use a thin Au film with a gap in the middle, measuring the drain current from the films, much as people normally use the jaws of slits. Now, I'd like to find a couple of current amplifiers which are small enough so that they can be connected with very short cables to the BNC connectors on the air-side of this detector, and which would have decent frequency response and low noise with inputs of the order of 0.1-1nA. Although this topic is outside the realm of XAFS analysis with IFEFFIT, I figure that people on this group might have some good experience. mam ___ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit -- Carlo U. Segre -- Duchossois Leadership Professor of Physics Interim Chair, Department of Chemistry Director, Center for Synchrotron Radiation Research and Instrumentation Illinois Institute of Technology Voice: 312.567.3498Fax: 312.567.3494 se...@iit.edu http://phys.iit.edu/~segre se...@debian.org ___ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit
Re: [Ifeffit] current-amp recommendation
Hi Matthew, At NSLS-II, we use a solution developed here at BNL for quad BPMs and other current-measurement operations. (I am using it for ion chambers at my beam line.) It is a box developed in the Instrumentation Division with a current amplifier, an A2D converter, and a microprocessor all inside a box that's about the size of a box of Pop Tarts. It has 4 SMA input channels and a single gain for all four channels. SMA to BNC cables are readily available from all the standard vendors. The output is an ethernet cable. The microprocessor runs a small debian system and starts an EPICS IOC and a DHCP client on boot. the 4 current get exposed as 4 PVs and the IOC does a lot of useful statistics on the fly. Seems to work pretty well. You could contact Pete Siddons. (Search for Siddons at the BNL website. When I tried it, the second hit was his staff page.) B On 11/14/2017 03:16 PM, Matthew Marcus wrote: I've gotten involved with a project in which stabilization of the position of a monochromatic, soft X-ray beam is needed. The offending frequencies seem to be vibration frequencies like 57 and 116Hz. We have in mind to use a thin Au film with a gap in the middle, measuring the drain current from the films, much as people normally use the jaws of slits. Now, I'd like to find a couple of current amplifiers which are small enough so that they can be connected with very short cables to the BNC connectors on the air-side of this detector, and which would have decent frequency response and low noise with inputs of the order of 0.1-1nA. Although this topic is outside the realm of XAFS analysis with IFEFFIT, I figure that people on this group might have some good experience. mam ___ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit -- Bruce Ravel bra...@bnl.gov National Institute of Standards and Technology Synchrotron Science Group at NSLS-II Building 743, Room 114 Upton NY, 11973 Homepage:http://bruceravel.github.io/home/ Beamline:https://www.bnl.gov/ps/beamlines/beamline.php?r=6-BM Software:https://github.com/bruceravel Demeter: http://bruceravel.github.io/demeter/ ___ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit
[Ifeffit] current-amp recommendation
I've gotten involved with a project in which stabilization of the position of a monochromatic, soft X-ray beam is needed. The offending frequencies seem to be vibration frequencies like 57 and 116Hz. We have in mind to use a thin Au film with a gap in the middle, measuring the drain current from the films, much as people normally use the jaws of slits. Now, I'd like to find a couple of current amplifiers which are small enough so that they can be connected with very short cables to the BNC connectors on the air-side of this detector, and which would have decent frequency response and low noise with inputs of the order of 0.1-1nA. Although this topic is outside the realm of XAFS analysis with IFEFFIT, I figure that people on this group might have some good experience. mam ___ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit
Re: [Ifeffit] Consult a few questions about XAS data analysis
Hi Jun, Two points so Bruce doesn't get two upset. If you included the Athena project you used for the lcf and maybe an excel file of the results you got, then someone could Check what you did, as it is there is almost no way to offer an opinion on that. Bruce gave a course at Dimaond several years ago now, but most of what he shows is relatively as true as it was the day he said it. The videos can be found here. http://www.diamond.ac.uk/Beamlines/Spectroscopy/Techniques/XAS.html The VLC media player works well with them. Regards Fred J.F.W. Mosselmans Principal Beamline Scientist I18 Diamond Light Source Ltd Diamond House Harwell Campus Didcot OX11 0DE P + 44 1235 778568 M + 44 7785510211 E fred.mosselm...@diamond.ac.uk orcid.org/-0001-6473-2743 [cid:image002.png@01D27563.28EDA240] -- This e-mail and any attachments may contain confidential, copyright and or privileged material, and are for the use of the intended addressee only. If you are not the intended addressee or an authorised recipient of the addressee please notify us of receipt by returning the e-mail and do not use, copy, retain, distribute or disclose the information in or attached to the e-mail. Any opinions expressed within this e-mail are those of the individual and not necessarily of Diamond Light Source Ltd. Diamond Light Source Ltd. cannot guarantee that this e-mail or any attachments are free from viruses and we cannot accept liability for any damage which you may sustain as a result of software viruses which may be transmitted in or with the message. Diamond Light Source Limited (company no. 4375679). Registered in England and Wales with its registered office at Diamond House, Harwell Science and Innovation Campus, Didcot, Oxfordshire, OX11 0DE, United Kingdom ___ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit
Re: [Ifeffit] Consult a few questions about XAS data analysis
Le 14.11.2017 15:32, Zhang, Guanghui a écrit : Jun, You can find many of Bruce's presentations on XAS through this link. http://bruceravel.github.io/XAS-Education/ [1] Bruce also wrote a very nice Artemis user's guide. I would suggest you to take a look. https://bruceravel.github.io/demeter/documents/Artemis/index.html [2] Good luck! -- Regards, Guanghui At 2017-11-14 14:21:38, "Jun Ge"wrote: Hi Bruce I'm a learner for XAS data analysis because of the need of scientific research. I have been to SLAC in San Francisco three times last year and collected some XAS data of samples and models in Beamline 7-3. This summer, I began to learn how to analyze these XAS data. My professor used to use WinXAS to analyze data. But this time he asked me to learn Athena. He thinks use two different softwares can double check the result. After the data pro-processing, including background remove and data normalization, etc., I save each spectrum in the form .txt. However, IN THE SAME ENERGY RANGE AND SAME FILE OF SAMPLE AND MODELS, THE RESULT OF LCF PERFORMED BY WINXAS AND ATHENA WAS TOTALLY DIFFERENT! I try to solve this problem for a long time but no progress was made. So I turn to you and Ressler (the author of WinXAS) for help. I guess may be the algorithm is different between your Athena with WinXAS, but I'm not sure. With great experience in XAS data analysis, I think it's easy for you to solve this problem, isn't it? By the way, I DON'T KNOW HOW TO FIT THE COORDINATION NUMBER IN ANOTHER SOFTWARE CALLED ARTEMIS in the software package of Demeter. I was told by Artemis that the coordination number can only be a number not alphabet. So I have no idea how to do this (yeah, I'm really a noob orz). And I don't know how to set the parameter more correctly to run a excellent Feff fit. So could you please help me? Finally, I WANT TO LEARN XAS DATA ANALYSIS SYSTEMATICALLY. SO COULD YOU PLEASE RECOMMEND ME SOME REFERENCES LIKE BOOKS OR PAPERS? Anyway, thanks a lot for your help and your precious time! Sincerely, Jun Ge Links: -- [1] http://bruceravel.github.io/XAS-Education/ [2] https://bruceravel.github.io/demeter/documents/Artemis/index.html -- Morgane DESMAU Doctorant/PhD student Institut de Physique du Globe de Paris Équipe de Géochimie des Eaux 1, rue Jussieu - 75238 Paris cedex 05 Mail: des...@ipgp.fr Phone: +33 1 83 95 77 33 ___ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit
Re: [Ifeffit] Consult a few questions about XAS data analysis
Jun, You can find many of Bruce's presentations on XAS through this link. http://bruceravel.github.io/XAS-Education/ Bruce also wrote a very nice Artemis user's guide. I would suggest you to take a look. https://bruceravel.github.io/demeter/documents/Artemis/index.html Good luck! -- Regards, Guanghui At 2017-11-14 14:21:38, "Jun Ge"wrote: Hi Bruce I'm a learner for XAS data analysis because of the need of scientific research. I have been to SLAC in San Francisco three times last year and collected some XAS data of samples and models in Beamline 7-3. This summer, I began to learn how to analyze these XAS data. My professor used to use WinXAS to analyze data. But this time he asked me to learn Athena. He thinks use two different softwares can double check the result. After the data pro-processing, including background remove and data normalization, etc., I save each spectrum in the form .txt. However, in the same energy range and same file of sample and models, the result of LCF performed by WinXAS and Athena was totally different! I try to solve this problem for a long time but no progress was made. So I turn to you and Ressler (the author of WinXAS) for help. I guess may be the algorithm is different between your Athena with WinXAS, but I'm not sure. With great experience in XAS data analysis, I think it's easy for you to solve this problem, isn't it? By the way, I don't know how to fit the Coordination Number in another software called Artemis in the software package of Demeter. I was told by Artemis that the coordination number can only be a number not alphabet. So I have no idea how to do this (yeah, I'm really a noob orz). And I don't know how to set the parameter more correctly to run a excellent Feff fit. So could you please help me? Finally, I want to learn XAS data analysis systematically. So could you please recommend me some references like books or papers? Anyway, thanks a lot for your help and your precious time! Sincerely, Jun Ge___ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit Unsubscribe: http://millenia.cars.aps.anl.gov/mailman/options/ifeffit