From: Adam T. <ate...@gm...> - 2017-11-28 17:32:55
|
Are you using 1.5? Or one of the newer releases like 1.5.2? If you're still having problems with the latest release, are you able to share your file for some debugging? On Tue, Nov 28, 2017 at 12:11 AM Martin Rahm <mar...@gm...> wrote: > Hi cclib-lovers, > > I've recently updated from 1.3 to 1.5, and I'm seeing some peculiarities > with the basic parsing. Maybe this has been explained somewhere, and if so > I apologize. I have been unable to find an answer on my own, and hope you > can help. I'm running a Linux environment with Python 3.6 (I used to run > 2.7.5 so that might have affected things as well). > > from cclib.parser import ccopen > > seem to have been replaced by > > from cclib.io import ccopen > > > so the basic guide shown https://cclib.github.io/methods.html doesn't > seem to be right anymore. > > > ccopen doesn't seem to function as it used to. > > data = ccopen("file.out") results in the following error: > > > File > "/c3se/users/rahmma/Hebbe/.local/lib/python3.6/site-packages/cclib/io/ccio.py", > line 190, in ccopen > > inputfile.seek(0, 0) > > AttributeError: 'FileInput' object has no attribute 'seek' > > This led me to use the (new?) functions: > > from cclib.parser import Gaussian ORCA > > > when calling > > data = ORCA("inputfile.out") > > > This seems to work, albeit sometimes with the following omnious error > messages: > > [ORCA ['./script.py', 'file.out'] WARNING] Attribute atomnos changed value > ([7, 6, 6, 8, 8] -> [7, 6, 7, 8, 8]) > > [ORCA ['./script.py', 'file.out'] WARNING] The geotargets attribute should > not exist yet. There is a problem in the parser. > > > when instead calling > > data = Gaussian("file.out") > > > it proceeds to crash at the next line, which is > > data = data.parse() > > > Traceback (most recent call last): > > File "./script.py", line 87, in <module> > > data = data.parse() > > File > "/c3se/users/rahmma/Hebbe/.local/lib/python3.6/site-packages/cclib/parser/logfileparser.py", > line 301, in parse > > self.extract(inputfile, line) > > File > "/c3se/users/rahmma/Hebbe/.local/lib/python3.6/site-packages/cclib/parser/gaussianparser.py", > line 163, in extract > > line = inputfile.next() > > AttributeError: 'FileInput' object has no attribute 'next' > > > So, to sum up, my questions are: > > > 1. Can cclib no longer automatically determine which output it is trying > to parse (ccopen could do this, and there was nothing fancy with the output > files I tried)? > > > 2. Do the the errors shown for the ORCA parser imply a real problem > > > 3. How do I get the Gaussian parser to run? > > > Many thanks, > > > Martin > > > > > ------------------------------------------------------------------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > _______________________________________________ > cclib-users mailing list > ccl...@li... > https://lists.sourceforge.net/lists/listinfo/cclib-users > |