|
From: | Michael Winokur |
Subject: | Re: [ESPResSo-users] Espresso input/output with Python |
Date: | Wed, 28 Dec 2016 12:47:08 -0600 |
Hi Michael,I dont know which guideline you followed but what should work is:- cd into the espresso folder- mkdir build- cd build- cmake ..- makeYou should be able to run the tests and use the h5md features. However if cmake prints some errors or missing libs (h5 lib e.g. should be the mpi parallelized one) you might not be able to use all features of espresso.Cheers KaiKai SzuttorInstitute for Computational PhysicsUniversität Stuttgart
Allmandring 3
Room 1.084
70569 Stuttgart, Germany
Phone: +49(0)711/685-67707 MichaelThanks again,How should I proceed?So clearly something is still amiss.with this messageHowever the following line breaks: "h5_file = h5md.H5md(filename="sample.h5"I tried copying these files "by hand" from the python source branch into my working directory. The above line worked and now there are also *.pyc files in this directory.4. After the build (no error) I note the the directory ~/core/src/python/espressomd/3. I presume that I must still customize myconfig.hpp2. The build using the python branch is a little cryptic because cmake breaks if I simply follow the directions. After three minor changes (it is not clear that all three were needed) the source builds (I am on the learning curve with cmake but no matter).1. My e-mail to espressomd-users is getting a rejection notice (but clearly it is getting through)Hello Kai,Thanks for the quick response. There are still a few issues:io/writer was missing h5md.py and __init__.py so this line "from espressomd.io.writer import h5md # pylint: disable=import-error" in the test program failed. , write_pos=True, write_vel=True,
write_force=True, write_type=True, write_mass=False)"
terminate called after throwing an instance of 'std::domain_error'
what(): Class 'ScriptInterface::Writer::H5mdScript' not found.
[romano5:16742] *** Process received signal ***
[romano5:16742] Signal: Aborted (6)
[romano5:16742] Signal code: (-6)
[romano5:16742] [ 0] /lib/x86_64-linux-gnu/libpthread.so.0(+0x11100)[ 0x7f014eb57100]
[romano5:16742] [ 1] /lib/x86_64-linux-gnu/libc.so.6(gsignal+0xcf)[ 0x7f014deb5fdf]
[romano5:16742] [ 2] /lib/x86_64-linux-gnu/libc.so.6(abort+0x16a)[0x7f014deb740a]
[romano5:16742] [ 3] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(_ZN9__gnu_ cxx27__verbose_terminate_ handlerEv+0x15d)[ 0x7f014724a04d]
[romano5:16742] [ 4] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0x8f016)[ 0x7f0147248016]
[romano5:16742] [ 5] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0x8f061)[ 0x7f0147248061]
[romano5:16742] [ 6] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0x8f279)[ 0x7f0147248279]
[romano5:16742] [ 7] /home/winokur/Espresso/espresso-utd/core/src/script_ interface/ libEspressoScriptInterface.so( _ ZN15ScriptInterface19ScriptInt erfaceBase11make_ sharedERKNSt7__cxx1112basic_ stringIcSt11char_ traitsIcESaIcEEENS0_ 14CreationPolicyE+0xa0b)[ 0x7f0149dd070b]
[romano5:16742] [ 8] /home/winokur/Espresso/espresso-utd/core/src/script_ interface/ libEspressoScriptInterface.so( _ ZN15ScriptInterface23ParallelS criptInterfaceC1ERKNSt7__ cxx1112basic_stringIcSt11char_ traitsIcESaIcEEE+0x1eb)[ 0x7f0149df540b]
[romano5:16742] [ 9] /home/winokur/Espresso/espresso-utd/core/src/script_ interface/ libEspressoScriptInterface.so( _ ZN15ScriptInterface19ScriptInt erfaceBase11make_ sharedERKNSt7__cxx1112basic_ stringIcSt11char_ traitsIcESaIcEEENS0_ 14CreationPolicyE+0x10d)[ 0x7f0149dcfe0d]
[romano5:16742] [10] /home/winokur/Espresso/espresso-utd/core/src/python/ espressomd/script_interface. so(+0x101c0)[0x7f0145e041c0]
[romano5:16742] [11] /usr/bin/python(+0xed414)[0x55aad6ef6414]
[romano5:16742] [12] /usr/bin/python(PyObject_Call+0x43)[0x55aad6ef08f3]
[romano5:16742] [13] /usr/bin/python(PyEval_EvalFrameEx+0x60ff)[ 0x55aad6f09c6f]
[romano5:16742] [14] /usr/bin/python(PyEval_EvalCodeEx+0x255)[ 0x55aad6f02345]
[romano5:16742] [15] /usr/bin/python(+0x1161a8)[0x55aad6f1f1a8]
[romano5:16742] [16] /usr/bin/python(PyObject_Call+0x43)[0x55aad6ef08f3]
[romano5:16742] [17] /usr/bin/python(+0x12c54e)[0x55aad6f3554e]
[romano5:16742] [18] /usr/bin/python(PyObject_Call+0x43)[0x55aad6ef08f3]
[romano5:16742] [19] /usr/bin/python(+0x12c287)[0x55aad6f35287]
[romano5:16742] [20] /usr/bin/python(+0xed414)[0x55aad6ef6414]
[romano5:16742] [21] /usr/bin/python(PyObject_Call+0x43)[0x55aad6ef08f3]
[romano5:16742] [22] /usr/bin/python(PyEval_EvalFrameEx+0x60ff)[ 0x55aad6f09c6f]
[romano5:16742] [23] /usr/bin/python(PyEval_EvalCodeEx+0x255)[ 0x55aad6f02345]
[romano5:16742] [24] /usr/bin/python(PyEval_EvalCode+0x19)[0x55aad6f020e9]
[romano5:16742] [25] /usr/bin/python(+0x1293af)[0x55aad6f323af]
[romano5:16742] [26] /usr/bin/python(PyRun_InteractiveOneFlags+0x199)[ 0x55aad6e8c745]
[romano5:16742] [27] /usr/bin/python(PyRun_InteractiveLoopFlags+0xc6)[ 0x55aad6e8c499]
[romano5:16742] [28] /usr/bin/python(+0x65bfc)[0x55aad6e6ebfc]
[romano5:16742] [29] /usr/bin/python(Py_Main+0x6c1)[0x55aad6eddfb1]
[romano5:16742] *** End of error message ***On Fri, Dec 23, 2016 at 2:51 AM, Kai Szuttor <address@hidden> wrote:Hi Michael,
please use the python branch if you want the latest features of the
python interface. There is an in-core implementation of the hdf5 format
which is documented and also has a sample script.
Please keep in mind that you have to install the hdf5-plugin for VMD
available on github in order to be able to read the written h5 files of
espresso.
As far as I know the imd stuff is not ported and won't be ported to
python, instead we have an openGL and mayavi visualization (also
available in the python branch).
Cheers,
Kai
On Thu, Dec 22, 2016 at 04:46:25PM -0600, Michael Winokur wrote:
> Hello,
>
> I am starting to make sure I can use some basic functions and it seems
> that the best way at present to transfer data to VMD is by the hdf5
> read/write functions.A I've been trying to get hdmd5_Write.py to work but
> this sample file generates an error message:A
>
> Traceback (most recent call last):
> A File "<stdin>", line 35, in <module>
> A File "espressomd/h5md.pyx", line 247, in
> espressomd.h5md.write_to_h5.pos
> (/home/winokur/Espresso/espresso-master/build/src/python/ espressomd/h5md.cpp:7376)
> AttributeError: 'System' object has no attribute 'n_part'
>
> My version of Espresso is from the "master" git download.A
>
> Also, will the imd communication protocol be ported to Python?
>
> Thanks,
>
> Michael
[Prev in Thread] | Current Thread | [Next in Thread] |