Page 1 of 2
GPU trajectories with standard FAHViewer
Posted: Wed Dec 23, 2015 11:13 pm
by ChristianVirtual
For those interested I modified a script I wrote last year for my iPad app to visualize GPU trajectories. Since I went a different route for the iPad I wanted to open up the script and enable it for use with the standard viewer.
https://github.com/ChristianVirtual/FAH ... Trajectory
An early version, working with Linux. If one with a Windows box want to help testing/changing: help is always welcomed.
Re: GPU trajectories with standard FAHViewer
Posted: Wed Dec 23, 2015 11:53 pm
by jimerickson
thanks for this little christmas gift ChristianVirtual!
just set it up on a second machine and am getting the following:
ERROR:Exception: Size of positions 5533 does not match topology 5532
what am i doing wrong?
Re: GPU trajectories with standard FAHViewer
Posted: Thu Dec 24, 2015 12:31 am
by ChristianVirtual
My pleasure ! Glad you like it.
I guess you are doing nothing wrong ... Can you send me three files from the working folder:
/var/lib/fahclient/work/<wu>/01/viewerTop.json for the atoms
/var/lib/fahclient/work/<wu>/01/viewerFrame1.json for the coordinates
/var/lib/fahclient/work/<wu>/01/system.xml for the bonds
Please grep, if there is no passkey from you in, just to make sure; if you have Dropbox or google drive please send me the link (also PM ok). If you don't have let me know; I can try to set one up.
Re: GPU trajectories with standard FAHViewer
Posted: Thu Dec 24, 2015 1:00 am
by jimerickson
Re: GPU trajectories with standard FAHViewer
Posted: Thu Dec 24, 2015 1:38 pm
by ChristianVirtual
Hello jimerickson,
please try the latest version from github; there where a number a atoms in some trajectories not converted properly; there might be some more of them. I'm on the search for a universal element data file with all atoms, their radius and mass, and other data. Not that easy to find a clear "free-to-use" data source.
The error message you mentioned might be linked to it though the files you send actually have less atoms (4410). And actually where did you see that message ? on the console from the python script ?
But pls check it out and let me know if it got better.
Re: GPU trajectories with standard FAHViewer
Posted: Thu Dec 24, 2015 3:42 pm
by jimerickson
it works!! and yes i saw that message on the console from the python script.
Re: GPU trajectories with standard FAHViewer
Posted: Mon Dec 28, 2015 8:54 pm
by toTOW
I tried it on Windows 8.1 64 bits with Python 3.5.1 and after changing the hostnames and the path, I'm getting the following error :
Code: Select all
(c) Christian Lohmann 2015
FAH_WrapperGPUTrajectory
2015-12-28:09:48:46:************************************************************
******
2015-12-28:09:48:46:* (c) Christian Lohmann, 2015
*
2015-12-28:09:48:46:* FAH_WrapperGPUTrajectory
*
2015-12-28:09:48:46:************************************************************
******
2015-12-28:09:48:46:
2015-12-28:09:48:46:start GPU wrapper on host localhost port 36331
2015-12-28:09:48:46:connecting to FAHClient on host localhost port 36330
2015-12-28:09:48:47:Trajectory server created with socket ('127.0.0.1', 36331)
2015-12-28:09:48:47:Trajectory client created with socket ('127.0.0.1', 49676)
2015-12-28:09:48:47:unexpected error <class 'TypeError'>
Traceback (most recent call last):
File "D:\FAH_WrapperGPUTrajectory.py", line 667, in FAHMM_Wrapper_GPU_Trajecto
ry
startPos = clientData.find(startTag)
TypeError: a bytes-like object is required, not 'str'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\FAH_WrapperGPUTrajectory.py", line 744, in <module>
FAHMM_Wrapper_GPU_Trajectory(hostnameWrapper, portWrapper, hostnameClient, p
ortClient)
File "D:\FAH_WrapperGPUTrajectory.py", line 732, in FAHMM_Wrapper_GPU_Trajecto
ry
logging.error("backtrace\n%s", sys.exc_traceback.tb_lineno)
AttributeError: module 'sys' has no attribute 'exc_traceback'
Re: GPU trajectories with standard FAHViewer
Posted: Mon Dec 28, 2015 9:48 pm
by ChristianVirtual
@toTOw: do you have also Python 2.7 on Windiws ?
Python 3.x has quite some differences I need to adopt for. It's on the todo list
Re: GPU trajectories with standard FAHViewer
Posted: Tue Dec 29, 2015 11:43 am
by ChristianVirtual
@toTOw: can you please try once more ?
Should work with Python 3 now (at least with the 3.4 I had on Linux; and still 2.7 too); you also don't need to adjust the path and hostname anymore. The script is reading it now from the data provided by the API. Whatever is configured will be used.
python ./FAH_WrapperGPUTrajectory.py
Code: Select all
2015-12-29:08:56:12:******************************************************************
2015-12-29:08:56:12:* (c) Christian Lohmann, 2015 *
2015-12-29:08:56:12:* FAH_WrapperGPUTrajectory *
2015-12-29:08:56:12:******************************************************************
2015-12-29:08:56:12:
2015-12-29:08:56:12:running Python 2.7.5
2015-12-29:08:56:12:start GPU wrapper on host linuxpowered port 36331
2015-12-29:08:56:12:connecting to FAHClient on host linuxpowered port 36330
python3.4 ./FAH_WrapperGPUTrajectory.py
Code: Select all
2015-12-29:08:52:59:******************************************************************
2015-12-29:08:52:59:* (c) Christian Lohmann, 2015 *
2015-12-29:08:52:59:* FAH_WrapperGPUTrajectory *
2015-12-29:08:52:59:******************************************************************
2015-12-29:08:52:59:
2015-12-29:08:52:59:running Python 3.4.3
Versions of Python depend on individual installations ... hopefully working with Windows this way
Re: GPU trajectories with standard FAHViewer
Posted: Tue Dec 29, 2015 12:43 pm
by davidcoton
Hey, we're getting there.
Tried on Win Vista, nVidia 980 running Core18.
On v1.4, set the two PCs to localhost. Got the Viewer screen with the correct GPU project details (Core 18), but no simulation graphics.
On v2.0. still had to set localhost in two places. Only got the demo.
Suggestion: can your wrapper launch the Viewer ? And somehow select the host form those on my network? (I have two PCs, one Win, one headless Ubuntu, that both fold).
Re: GPU trajectories with standard FAHViewer
Posted: Tue Dec 29, 2015 12:52 pm
by ChristianVirtual
@davidcoton:
actually the wrapper need to run on each system; on the windows box and also on the linux.
from one PC you can then start the viewer and connect to the wrapper (thats why also the script can't/shouldn't start the viewer); ideally the wrapper get put into background and forgotten
As for the simulation: can you please try once to close the viewer and start it again ... keep then script running. I had a similar experience in earlier times but was not able to reproduce.
Re: GPU trajectories with standard FAHViewer
Posted: Tue Dec 29, 2015 4:36 pm
by davidcoton
OK, after some work I've now got v2.1 working on Win and Linux, including viewing work on opposite PCs. Awesome. Thanks, CV.
Re: GPU trajectories with standard FAHViewer
Posted: Tue Dec 29, 2015 7:02 pm
by jimerickson
sorry to bother you guys but could one of you write a quick and dirty tutorial on how you get the viewer to work when called remotely? i am really stumped by this. just getting the demo protien. again i apologize for this.
edit: ah i get now. ok this is wonderful. got my laptop rendering from one of my folding rigs. excellent work ChristianVirtual!
Re: GPU trajectories with standard FAHViewer
Posted: Tue Dec 29, 2015 8:05 pm
by toTOW
ChristianVirtual> the wrapper now starts fine on Windows/python 3.5.1. On first startup, Windows Firewall asks for permissions.
But I didn't go further : does anyone know how to start two command prompts in Windows 8.1 ?
Re: GPU trajectories with standard FAHViewer
Posted: Tue Dec 29, 2015 9:22 pm
by ChristianVirtual
toTOW wrote:But I didn't go further : does anyone know how to start two command prompts in Windows 8.1 ?
that's made me smile a bit
Try this
http://answers.microsoft.com/en-us/wind ... c4a?auth=1