[Ifeffit] LARCH installation issue in UBUNTU 18

Matt Newville newville at cars.uchicago.edu
Wed Dec 5 10:17:55 CST 2018


Hi Mahendra,

On Wed, Dec 5, 2018 at 6:28 AM Uma Mahendra Kumar K <umamahendra at vit.ac.in>
wrote:

> Dear All,
>
>               I wanted to install LARCH on Ubuntu 18. And I could not.
>
> I have tried several methods  (miniconda, Anaconda, from source and the
> Linux Binaries and even through pip).
>
>  For several issues , I found answers in Ifeffit mailing list. This is new.
>
> lmfit is not able to import 'ufloat'.
>
> Actually "ufloat" belongs to "uncertainties". I could not able to
> link(port) them properly.
>
> I need your help to install Larch.
>
> the following is the error message
>
> Traceback (most recent call last):
>   File "/usr/local/bin/larch", line 58, in <module>
>     import larch
>   File "/root/.local/lib/python2.7/site-packages/larch/__init__.py", line
> 25, in <module>
>     from .shell import shell
>   File "/root/.local/lib/python2.7/site-packages/larch/shell.py", line 10,
> in <module>
>     from .interpreter import Interpreter
>   File "/root/.local/lib/python2.7/site-packages/larch/interpreter.py",
> line 18, in <module>
>     from . import builtins
>   File "/root/.local/lib/python2.7/site-packages/larch/builtins.py", line
> 22, in <module>
>     from . import fitting
>   File
> "/root/.local/lib/python2.7/site-packages/larch/fitting/__init__.py", line
> 20, in <module>
>     from lmfit import (Parameter, Parameters, Minimizer, conf_interval,
> ImportError: cannot import name ufloat
>
>
Oh, very sorry for the trouble.  That is totally my fault, and something I
realize is not very well tested.   Basically, lmfit (which I am at least
partly responsible for) had a new release (0.9.12) that breaks larch
0.9.40, in exactly this place.  The unreleased, development version of
larch does work with the latest version (so all the tests say everything is
fine).   I'm working on getting 0.9.41 released soon (hopefully next week),
but that doesn't solve the problem for you now.

The first thing to try is:
       pip install lmfit==0.9.11

I think that *should* work.  If there are still problems, I would forcibly
remove .../python2.7/site-packages/lmfit* and then install lmfit version
0.9.11.

As an aside, I might recommend using a version of Python that is not
installed as root and in the /root/.local.    That seems slightly dangerous
to me.

Hope that helps,

--Matt
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://millenia.cars.aps.anl.gov/pipermail/ifeffit/attachments/20181205/d127d7b1/attachment.html>


More information about the Ifeffit mailing list