Previous Thread
Next Thread
Print Thread
Python subroutine
#37266 01/11/19 09:10 PM
Joined: Sep 2018
Posts: 10
C
ca4930 Offline OP
Forum Member
OP Offline
Forum Member
C
Joined: Sep 2018
Posts: 10
I'd like to incorporate a python subroutine in my charmm script. Can I do this via USERSB? If so how?

Last edited by ca4930; 01/11/19 09:41 PM.
Re: Python subroutine
ca4930 #37267 01/11/19 09:45 PM
Joined: Sep 2003
Posts: 8,582
Likes: 11
rmv Online Content
Forum Member
Online Content
Forum Member
Joined: Sep 2003
Posts: 8,582
Likes: 11
The system command should return control to the CHARMM script when it completes. If you want to pass some data back to CHARMM, the python script should write a stream file, which can then be read by a subsequent CHARMM command.

In principle, you can use Fortran to call system() under Linux, but you'd still have an issue with using any data produced, as Fortran cannot read python data objects directly.


Rick Venable
computational chemist


Moderated by  lennart, rmv 

Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.4
(Release build 20200307)
Responsive Width:

PHP: 7.3.31-1~deb10u1 Page Time: 0.007s Queries: 18 (0.004s) Memory: 0.7172 MB (Peak: 0.7528 MB) Data Comp: Off Server Time: 2021-12-08 00:59:38 UTC
Valid HTML 5 and Valid CSS