Skip to content

Instantly share code, notes, and snippets.

@iwatobipen
Created January 3, 2025 09:25
Show Gist options
  • Select an option

  • Save iwatobipen/f84600324d3f04cdcb5c494fa26cf1fa to your computer and use it in GitHub Desktop.

Select an option

Save iwatobipen/f84600324d3f04cdcb5c494fa26cf1fa to your computer and use it in GitHub Desktop.
Display the source blob
Display the rendered blob
Raw
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"id": "3680211d-46dd-4a18-a141-5a471de04551",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:14.840676Z",
"iopub.status.busy": "2025-01-03T07:01:14.840544Z",
"iopub.status.idle": "2025-01-03T07:01:15.041839Z",
"shell.execute_reply": "2025-01-03T07:01:15.041576Z",
"shell.execute_reply.started": "2025-01-03T07:01:14.840665Z"
}
},
"outputs": [
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "1bc9eec2161143cfae3b0606050f2b9d",
"version_major": 2,
"version_minor": 0
},
"text/plain": []
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"import nglview\n",
"import ipywidgets\n",
"import os\n",
"import zipfile\n",
"import sys\n",
"\n",
"pdbCode = '3HTB'\n",
"ligandCode = 'JZ4'\n",
"mol_charge = 0"
]
},
{
"cell_type": "code",
"execution_count": 2,
"id": "dabef0ab-5eca-47a6-b8fe-37ae6bc331ba",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:16.194152Z",
"iopub.status.busy": "2025-01-03T07:01:16.194004Z",
"iopub.status.idle": "2025-01-03T07:01:18.317902Z",
"shell.execute_reply": "2025-01-03T07:01:18.317577Z",
"shell.execute_reply.started": "2025-01-03T07:01:16.194138Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:16,248 [MainThread ] [INFO ] Executing biobb_io.api.pdb Version: 4.2.0\n",
"2025-01-03 16:01:16,249 [MainThread ] [INFO ] Downloading 3htb from: https://www.ebi.ac.uk/pdbe/entry-files/download/pdb3htb.ent\n",
"2025-01-03 16:01:18,314 [MainThread ] [INFO ] Writting pdb to: 3HTB.orig.pdb\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 2,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from biobb_io.api.pdb import pdb\n",
"\n",
"downloaded_pdb = pdbCode+'.orig.pdb'\n",
"\n",
"prop = {\n",
" 'pdb_code': pdbCode,\n",
" 'filter' : False\n",
"}\n",
"pdb(output_pdb_path=downloaded_pdb,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 3,
"id": "3e79ce0a-b1be-4a6a-bc3d-d6de769cdeab",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:23.666805Z",
"iopub.status.busy": "2025-01-03T07:01:23.666354Z",
"iopub.status.idle": "2025-01-03T07:01:23.994870Z",
"shell.execute_reply": "2025-01-03T07:01:23.994590Z",
"shell.execute_reply.started": "2025-01-03T07:01:23.666791Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:23,709 [MainThread ] [INFO ] Executing biobb_structure_utils.utils.extract_heteroatoms Version: 4.2.0\n",
"2025-01-03 16:01:23,710 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB.orig.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/c76a9407-392d-4602-985c-ec649958d7b5\n",
"2025-01-03 16:01:23,729 [MainThread ] [INFO ] Writting pdb to: /home/iwatobipen/dev/sandbox/biobb_demo/c76a9407-392d-4602-985c-ec649958d7b5/JZ4.pdb\n",
"2025-01-03 16:01:23,730 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/c76a9407-392d-4602-985c-ec649958d7b5']\n",
"2025-01-03 16:01:23,731 [MainThread ] [INFO ] Executing biobb_structure_utils.utils.extract_molecule Version: 4.2.0\n",
"2025-01-03 16:01:23,731 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB.orig.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/1925b1b1-ef9f-465b-9129-7fe26e19417b\n",
"2025-01-03 16:01:23,732 [MainThread ] [INFO ] Creating 9887df7f-530a-4d42-a8ff-2a5deb2d089d temporary folder\n",
"2025-01-03 16:01:23,732 [MainThread ] [INFO ] check_structure -i /home/iwatobipen/dev/sandbox/biobb_demo/3HTB.orig.pdb -o 3HTB.pdb --force_save --non_interactive command_list --list 9887df7f-530a-4d42-a8ff-2a5deb2d089d/extract_prot.lst\n",
"\n",
"2025-01-03 16:01:23,988 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:23,989 [MainThread ] [INFO ] ================================================================================\n",
"= BioBB structure checking utility v3.13.4 =\n",
"= P. Andrio, A. Hospital, G. Bayarri, J.L. Gelpi 2018-23 =\n",
"================================================================================\n",
"\n",
"Warning: sequence features may not be available, use --sequence for external fasta input\n",
"Structure /home/iwatobipen/dev/sandbox/biobb_demo/3HTB.orig.pdb loaded\n",
" PDB id: 3HTB \n",
" Title: 2-propylphenol in complex with t4 lysozyme l99a/m102q\n",
" Experimental method: x-ray diffraction\n",
" Keywords: hydrolase, glycosidase, bacteriolytic enzyme, antimicrobial\n",
" Resolution (A): 1.81\n",
"\n",
" Num. models: 1\n",
" Num. chains: 1 (A: Protein)\n",
" Num. residues: 387\n",
" Num. residues with ins. codes: 0\n",
" Num. residues with H atoms: 0\n",
" Num. HETATM residues: 224\n",
" Num. ligands or modified residues: 4\n",
" Num. water mol.: 220\n",
" Num. atoms: 1544\n",
"Small mol ligands found\n",
"PO4 A165\n",
"PO4 A166\n",
"JZ4 A167\n",
"BME A168\n",
"\n",
"Step 1: ligands --remove All\n",
"\n",
"Running ligands. Options: --remove All\n",
"Detected 4 Ligands\n",
" PO4 A165\n",
" PO4 A166\n",
" JZ4 A167\n",
" BME A168\n",
"Ligands removed All (4)\n",
"\n",
"Step 2: water --remove Yes\n",
"\n",
"Running water. Options: --remove Yes\n",
"Detected 220 Water molecules\n",
"Removed 220 Water molecules\n",
"Command list completed\n",
"Final Num. models: 1\n",
"Final Num. chains: 1 (A: Protein)\n",
"Final Num. residues: 163\n",
"Final Num. residues with ins. codes: 0\n",
"Final Num. residues with H atoms: 0\n",
"Final Num. HETATM residues: 0\n",
"Final Num. ligands or modified residues: 0\n",
"Final Num. water mol.: 0\n",
"Final Num. atoms: 1300\n",
"Structure saved on 3HTB.pdb\n",
"\n",
"2025-01-03 16:01:23,990 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/1925b1b1-ef9f-465b-9129-7fe26e19417b', '9887df7f-530a-4d42-a8ff-2a5deb2d089d']\n",
"3HTB.pdb JZ4.pdb 3HTB_JZ4.pdb\n",
"2025-01-03 16:01:23,991 [MainThread ] [INFO ] Executing biobb_structure_utils.utils.cat_pdb Version: 4.2.0\n",
"2025-01-03 16:01:23,991 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/1b82abb6-bcd5-4d7e-a983-a23895b438f7\n",
"2025-01-03 16:01:23,992 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/JZ4.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/1b82abb6-bcd5-4d7e-a983-a23895b438f7\n",
"2025-01-03 16:01:23,992 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/1b82abb6-bcd5-4d7e-a983-a23895b438f7']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 3,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from biobb_structure_utils.utils.extract_heteroatoms import extract_heteroatoms\n",
"from biobb_structure_utils.utils.extract_molecule import extract_molecule\n",
"from biobb_structure_utils.utils.cat_pdb import cat_pdb\n",
"\n",
"proteinFile = pdbCode+'.pdb'\n",
"ligandFile = ligandCode+'.pdb'\n",
"complexFile = pdbCode+'_'+ligandCode+'.pdb'\n",
"\n",
"prop = {\n",
" 'heteroatoms' :[{'name':'JZ4'}]\n",
"}\n",
"\n",
"extract_heteroatoms(input_structure_path=downloaded_pdb,\n",
" output_heteroatom_path=ligandFile,\n",
" properties=prop)\n",
"\n",
"extract_molecule(input_structure_path=downloaded_pdb,\n",
" output_molecule_path=proteinFile)\n",
"\n",
"print(proteinFile, ligandFile, complexFile)\n",
"\n",
"cat_pdb(input_structure1=proteinFile,\n",
" input_structure2=ligandFile,\n",
" output_structure_path=complexFile)\n"
]
},
{
"cell_type": "code",
"execution_count": 4,
"id": "9701437e-c9dd-46e5-83a9-0e265aa4c36c",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:25.087605Z",
"iopub.status.busy": "2025-01-03T07:01:25.087394Z",
"iopub.status.idle": "2025-01-03T07:01:25.294745Z",
"shell.execute_reply": "2025-01-03T07:01:25.294419Z",
"shell.execute_reply.started": "2025-01-03T07:01:25.087585Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:25,105 [MainThread ] [INFO ] Executing biobb_model.model.fix_side_chain Version: 4.2.3\n",
"2025-01-03 16:01:25,106 [MainThread ] [INFO ] Copy: 3HTB.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/062769af-2cc9-4caf-ae32-1c08623fe3d3\n",
"2025-01-03 16:01:25,106 [MainThread ] [INFO ] check_structure -i /home/iwatobipen/dev/sandbox/biobb_demo/062769af-2cc9-4caf-ae32-1c08623fe3d3/3HTB.pdb -o /home/iwatobipen/dev/sandbox/biobb_demo/062769af-2cc9-4caf-ae32-1c08623fe3d3/3HTB_fixed.pdb --force_save fixside --fix ALL\n",
"\n",
"2025-01-03 16:01:25,291 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:25,292 [MainThread ] [INFO ] ================================================================================\n",
"= BioBB structure checking utility v3.13.4 =\n",
"= P. Andrio, A. Hospital, G. Bayarri, J.L. Gelpi 2018-23 =\n",
"================================================================================\n",
"\n",
"Warning: sequence features may not be available, use --sequence for external fasta input\n",
"Structure /home/iwatobipen/dev/sandbox/biobb_demo/062769af-2cc9-4caf-ae32-1c08623fe3d3/3HTB.pdb loaded\n",
" PDB id: \n",
" Title: \n",
" Experimental method: unknown\n",
" Resolution (A): N.A.\n",
"\n",
" Num. models: 1\n",
" Num. chains: 1 (A: Protein)\n",
" Num. residues: 163\n",
" Num. residues with ins. codes: 0\n",
" Num. residues with H atoms: 0\n",
" Num. HETATM residues: 0\n",
" Num. ligands or modified residues: 0\n",
" Num. water mol.: 0\n",
" Num. atoms: 1300\n",
"Running fixside. Options: --fix ALL\n",
"Found no residues with missing or unknown side chain atoms\n",
"Structure not modified, saving due to --force_save option\n",
"Final Num. models: 1\n",
"Final Num. chains: 1 (A: Protein)\n",
"Final Num. residues: 163\n",
"Final Num. residues with ins. codes: 0\n",
"Final Num. residues with H atoms: 0\n",
"Final Num. HETATM residues: 0\n",
"Final Num. ligands or modified residues: 0\n",
"Final Num. water mol.: 0\n",
"Final Num. atoms: 1300\n",
"Structure saved on /home/iwatobipen/dev/sandbox/biobb_demo/062769af-2cc9-4caf-ae32-1c08623fe3d3/3HTB_fixed.pdb\n",
"\n",
"2025-01-03 16:01:25,292 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/062769af-2cc9-4caf-ae32-1c08623fe3d3']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 4,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from biobb_model.model.fix_side_chain import fix_side_chain\n",
"fixed_pdb = pdbCode+'_fixed.pdb'\n",
"fix_side_chain(input_pdb_path=proteinFile,\n",
" output_pdb_path=fixed_pdb)"
]
},
{
"cell_type": "code",
"execution_count": 5,
"id": "9cea4244-4057-49fa-9b50-84237354f32a",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:25.552314Z",
"iopub.status.busy": "2025-01-03T07:01:25.552156Z",
"iopub.status.idle": "2025-01-03T07:01:25.665962Z",
"shell.execute_reply": "2025-01-03T07:01:25.665710Z",
"shell.execute_reply.started": "2025-01-03T07:01:25.552303Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:25,595 [MainThread ] [INFO ] Executing biobb_gromacs.gromacs.pdb2gmx Version: 4.2.0\n",
"2025-01-03 16:01:25,596 [MainThread ] [INFO ] Copy: 3HTB_fixed.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/d7eea0ca-71d7-401c-a341-823c17b361a4\n",
"2025-01-03 16:01:25,596 [MainThread ] [INFO ] gmx -nobackup -nocopyright pdb2gmx -f /home/iwatobipen/dev/sandbox/biobb_demo/d7eea0ca-71d7-401c-a341-823c17b361a4/3HTB_fixed.pdb -o /home/iwatobipen/dev/sandbox/biobb_demo/d7eea0ca-71d7-401c-a341-823c17b361a4/3HTB_pdb2gmx.gro -p p2g.top -water spce -ff amber99sb-ildn -i posre.itp\n",
"\n",
"2025-01-03 16:01:25,656 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:25,657 [MainThread ] [INFO ] Using the Amber99sb-ildn force field in directory amber99sb-ildn.ff\n",
"\n",
"going to rename amber99sb-ildn.ff/aminoacids.r2b\n",
"\n",
"going to rename amber99sb-ildn.ff/dna.r2b\n",
"\n",
"going to rename amber99sb-ildn.ff/rna.r2b\n",
"Reading /home/iwatobipen/dev/sandbox/biobb_demo/d7eea0ca-71d7-401c-a341-823c17b361a4/3HTB_fixed.pdb...\n",
"Read '', 1364 atoms\n",
"\n",
"Analyzing pdb file\n",
"Splitting chemical chains based on TER records or chain id changing.\n",
"\n",
"There are 1 chains and 0 blocks of water and 163 residues with 1364 atoms\n",
"\n",
" chain #res #atoms\n",
"\n",
" 1 'A' 163 1364 \n",
"\n",
"there were 0 atoms with zero occupancy and 178 atoms with occupancy unequal to one (out of 1364 atoms). Check your pdb file.\n",
"\n",
"Reading residue database... (Amber99sb-ildn)\n",
"\n",
"Processing chain 1 'A' (1364 atoms, 163 residues)\n",
"\n",
"Identified residue MET1 as a starting terminus.\n",
"\n",
"Identified residue ASN163 as a ending terminus.\n",
"\n",
"Checking for duplicate atoms....\n",
"\n",
"Now there are 1300 atoms. Deleted 64 duplicates.\n",
"\n",
"Generating any missing hydrogen atoms and/or adding termini.\n",
"\n",
"Now there are 163 residues with 2614 atoms\n",
"\n",
"Making bonds...\n",
"\n",
"Number of bonds was 2635, now 2634\n",
"\n",
"Generating angles, dihedrals and pairs...\n",
"\n",
"Making cmap torsions...\n",
"\n",
"There are 7252 dihedrals, 522 impropers, 4751 angles\n",
" 6847 pairs, 2634 bonds and 0 virtual sites\n",
"\n",
"Total mass 18512.384 a.m.u.\n",
"\n",
"Total charge 6.000 e\n",
"\n",
"Writing topology\n",
"\n",
"Writing coordinate file...\n",
"\n",
"\t\t--------- PLEASE NOTE ------------\n",
"\n",
"You have successfully generated a topology from: /home/iwatobipen/dev/sandbox/biobb_demo/d7eea0ca-71d7-401c-a341-823c17b361a4/3HTB_fixed.pdb.\n",
"\n",
"The Amber99sb-ildn force field and the spce water model are used.\n",
"\n",
"\t\t--------- ETON ESAELP ------------\n",
"\n",
"2025-01-03 16:01:25,657 [MainThread ] [INFO ] :-) GROMACS - gmx pdb2gmx, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx -nobackup -nocopyright pdb2gmx -f /home/iwatobipen/dev/sandbox/biobb_demo/d7eea0ca-71d7-401c-a341-823c17b361a4/3HTB_fixed.pdb -o /home/iwatobipen/dev/sandbox/biobb_demo/d7eea0ca-71d7-401c-a341-823c17b361a4/3HTB_pdb2gmx.gro -p p2g.top -water spce -ff amber99sb-ildn -i posre.itp\n",
"\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/aminoacids.r2b\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/dna.r2b\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/rna.r2b\n",
"there were 0 atoms with zero occupancy and 178 atoms with occupancy unequal to one (out of 1364 atoms). Check your pdb file.\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/atomtypes.atp\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/aminoacids.rtp\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/dna.rtp\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/rna.rtp\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/aminoacids.hdb\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/dna.hdb\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/rna.hdb\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/aminoacids.n.tdb\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/aminoacids.c.tdb\n",
"Analysing hydrogen-bonding network for automated assignment of histidine\n",
" protonation. 273 donors and 248 acceptors were found.\n",
"There are 347 hydrogen bonds\n",
"Will use HISD for residue 31\n",
"9 out of 9 lines of specbond.dat converted successfully\n",
"Special Atom Distance matrix:\n",
" MET1 MET6 HIS31 CYS54 CYS97 MET106\n",
" SD10 SD56 NE2276 SG446 SG808 SD883\n",
" MET6 SD56 0.631\n",
" HIS31 NE2276 2.196 1.931\n",
" CYS54 SG446 2.781 2.718 1.052\n",
" CYS97 SG808 0.820 0.539 2.117 2.897\n",
" MET106 SD883 1.900 1.314 1.848 2.841 1.635\n",
" MET120 SD982 2.525 2.014 3.286 4.293 2.112 1.520\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/aminoacids.arn\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/dna.arn\n",
"Opening force field file /usr/local/gromacs/share/gromacs/top/amber99sb-ildn.ff/rna.arn\n",
"Before cleaning: 6889 pairs\n",
"Before cleaning: 7252 dihedrals\n",
"\n",
"GROMACS reminds you: \"God is a DJ\" (Faithless)\n",
"\n",
"\n",
"2025-01-03 16:01:25,658 [MainThread ] [INFO ] Compressing topology to: 3HTB_pdb2gmx.top.zip\n",
"2025-01-03 16:01:25,658 [MainThread ] [INFO ] Ignored file amber99sb-ildn.ff/forcefield.itp\n",
"2025-01-03 16:01:25,662 [MainThread ] [INFO ] Ignored file amber99sb-ildn.ff/spce.itp\n",
"2025-01-03 16:01:25,662 [MainThread ] [INFO ] Ignored file amber99sb-ildn.ff/ions.itp\n",
"2025-01-03 16:01:25,663 [MainThread ] [INFO ] Adding:\n",
"2025-01-03 16:01:25,663 [MainThread ] [INFO ] ['p2g.top', 'posre.itp']\n",
"2025-01-03 16:01:25,663 [MainThread ] [INFO ] to: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_pdb2gmx.top.zip\n",
"2025-01-03 16:01:25,663 [MainThread ] [INFO ] Removed: ['posre.itp', 'p2g.top']\n",
"2025-01-03 16:01:25,664 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/d7eea0ca-71d7-401c-a341-823c17b361a4']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 5,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from biobb_gromacs.gromacs.pdb2gmx import pdb2gmx\n",
"output_pdb2gmx_gro = pdbCode+'_pdb2gmx.gro'\n",
"output_pdb2gmx_top_zip = pdbCode+'_pdb2gmx.top.zip'\n",
"prop = {'force_field':'amber99sb-ildn',\n",
" 'water_type':'spce'}\n",
"pdb2gmx(input_pdb_path=fixed_pdb,\n",
" output_gro_path=output_pdb2gmx_gro,\n",
" output_top_zip_path=output_pdb2gmx_top_zip,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 6,
"id": "6b094550-aa8a-4b60-b27c-7d96d2e102a5",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:26.297135Z",
"iopub.status.busy": "2025-01-03T07:01:26.296989Z",
"iopub.status.idle": "2025-01-03T07:01:26.541213Z",
"shell.execute_reply": "2025-01-03T07:01:26.540841Z",
"shell.execute_reply.started": "2025-01-03T07:01:26.297125Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:26,307 [MainThread ] [INFO ] Executing biobb_chemistry.ambertools.reduce_add_hydrogens Version: 4.2.1\n",
"2025-01-03 16:01:26,307 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/JZ4.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/71af10a4-d815-4c13-83a5-83e69844a266\n",
"2025-01-03 16:01:26,308 [MainThread ] [INFO ] reduce -NUClear -OH -ROTNH3 -ALLALT /home/iwatobipen/dev/sandbox/biobb_demo/71af10a4-d815-4c13-83a5-83e69844a266/JZ4.pdb > /home/iwatobipen/dev/sandbox/biobb_demo/71af10a4-d815-4c13-83a5-83e69844a266/JZ4.reduce_H.pdb\n",
"\n",
"2025-01-03 16:01:26,536 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:26,537 [MainThread ] [INFO ] Processing file: \"/home/iwatobipen/dev/sandbox/biobb_demo/71af10a4-d815-4c13-83a5-83e69844a266/JZ4.pdb\"\n",
"Building or keeping OH & SH Hydrogens.\n",
"WARNING: atom H13A from JZ4 will be treated as hydrogen\n",
"WARNING: atom H14A from JZ4 will be treated as hydrogen\n",
"WARNING: atom H13A from JZ4 will be treated as hydrogen\n",
"WARNING: atom H13A from JZ4 will be treated as hydrogen\n",
"WARNING: atom H14A from JZ4 will be treated as hydrogen\n",
"WARNING: atom H14A from JZ4 will be treated as hydrogen\n",
"WARNING: atom H14A from JZ4 will be treated as hydrogen\n",
"WARNING: atom H14A from JZ4 will be treated as hydrogen\n",
"WARNING: atom H13A from JZ4 will be treated as hydrogen\n",
"WARNING: atom H13A from JZ4 will be treated as hydrogen\n",
"WARNING: atom H14A from JZ4 will be treated as hydrogen\n",
"WARNING: atom H13A from JZ4 will be treated as hydrogen\n",
"VDW dot density = 16/A^2\n",
"Probe radius = 0.25A\n",
"Orientation penalty scale = 1 (100%)\n",
"Eliminate contacts within 3 bonds.\n",
"Ignore atoms with |occupancy| <= 0.01 during adjustments.\n",
"Waters ignored if B-Factor >= 40 or |occupancy| < 0.66\n",
"Aromatic rings in amino acids accept hydrogen bonds.\n",
"Rotating NH3 Hydrogens.\n",
"Not processing Met methyls.\n",
" Singles(size 1): A 167 JZ4 OAB \n",
" orientation 1: A 167 JZ4 OAB : rot 126: bump=0.000, HB=0.000, total=1.276\n",
"Found 0 hydrogens (0 hets)\n",
"Standardized 0 hydrogens (0 hets)\n",
"Added 12 hydrogens (12 hets)\n",
"Adjusted 1 group(s)\n",
"If you publish work which uses reduce, please cite:\n",
"Word, et. al. (1999) J. Mol. Biol. 285, 1735-1747.\n",
"For more information see http://kinemage.biochem.duke.edu\n",
"\n",
"2025-01-03 16:01:26,538 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/71af10a4-d815-4c13-83a5-83e69844a266']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 6,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from biobb_chemistry.ambertools.reduce_add_hydrogens import reduce_add_hydrogens\n",
"output_reduce_h = ligandCode+'.reduce_H.pdb'\n",
"prop = {'nuclear':'true',\n",
" }\n",
"reduce_add_hydrogens(input_path=ligandFile,\n",
" output_path=output_reduce_h,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 7,
"id": "99797543-b92a-4b62-ac36-41fa919d6426",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:27.181069Z",
"iopub.status.busy": "2025-01-03T07:01:27.180916Z",
"iopub.status.idle": "2025-01-03T07:01:27.191353Z",
"shell.execute_reply": "2025-01-03T07:01:27.191022Z",
"shell.execute_reply.started": "2025-01-03T07:01:27.181055Z"
}
},
"outputs": [],
"source": [
"from biobb_chemistry.babelm.babel_minimize import babel_minimize\n",
"# Create prop dict and inputs/outputs\n",
"output_babel_min = ligandCode+'.H.min.mol2' \n",
"prop = {\n",
" 'method' : 'sd',\n",
" 'criteria' : '1e-10',\n",
" 'force_field' : 'GAFF'\n",
"}\n"
]
},
{
"cell_type": "code",
"execution_count": 8,
"id": "ec35bc6b-5fcc-4e52-a659-085888af1884",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:28.358780Z",
"iopub.status.busy": "2025-01-03T07:01:28.358619Z",
"iopub.status.idle": "2025-01-03T07:01:28.621445Z",
"shell.execute_reply": "2025-01-03T07:01:28.621174Z",
"shell.execute_reply.started": "2025-01-03T07:01:28.358770Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:28,360 [MainThread ] [INFO ] Executing biobb_chemistry.babelm.babel_minimize Version: 4.2.1\n",
"2025-01-03 16:01:28,361 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/JZ4.reduce_H.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/fba7f47f-7f77-4aff-9402-49296ced2556\n",
"2025-01-03 16:01:28,361 [MainThread ] [INFO ] Hydrogens is not correct, assigned default value: False\n",
"2025-01-03 16:01:28,361 [MainThread ] [INFO ] Steps is not correct, assigned default value: 2500\n",
"2025-01-03 16:01:28,362 [MainThread ] [INFO ] Cut-off is not correct, assigned default value: False\n",
"2025-01-03 16:01:28,362 [MainThread ] [INFO ] Rvdw is not correct, assigned default value: 6.0\n",
"2025-01-03 16:01:28,362 [MainThread ] [INFO ] Rele is not correct, assigned default value: 10.0\n",
"2025-01-03 16:01:28,362 [MainThread ] [INFO ] Frequency is not correct, assigned default value: 10\n",
"2025-01-03 16:01:28,363 [MainThread ] [INFO ] obminimize -c 1e-10 -sd -ff GAFF -ipdb /home/iwatobipen/dev/sandbox/biobb_demo/fba7f47f-7f77-4aff-9402-49296ced2556/JZ4.reduce_H.pdb -omol2 > /home/iwatobipen/dev/sandbox/biobb_demo/fba7f47f-7f77-4aff-9402-49296ced2556/JZ4.H.min.mol2\n",
"\n",
"2025-01-03 16:01:28,618 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:28,618 [MainThread ] [INFO ] \n",
"A T O M T Y P E S\n",
"\n",
"IDX\tTYPE\tRING\n",
"1\tc3\tNO\n",
"2\tca\tAR\n",
"3\tca\tAR\n",
"4\tca\tAR\n",
"5\tca\tAR\n",
"6\tca\tAR\n",
"7\tca\tAR\n",
"8\tc3\tNO\n",
"9\tc3\tNO\n",
"10\toh\tNO\n",
"11\tho\tNO\n",
"12\thc\tNO\n",
"13\thc\tNO\n",
"14\tha\tNO\n",
"15\tha\tNO\n",
"16\tha\tNO\n",
"17\thc\tNO\n",
"18\thc\tNO\n",
"19\thc\tNO\n",
"20\thc\tNO\n",
"21\thc\tNO\n",
"22\tha\tNO\n",
"\n",
"C H A R G E S\n",
"\n",
"IDX\tCHARGE\n",
"1\t-0.064979\n",
"2\t-0.061278\n",
"3\t-0.058294\n",
"4\t-0.019907\n",
"5\t0.120013\n",
"6\t-0.055115\n",
"7\t-0.005954\n",
"8\t-0.024481\n",
"9\t-0.051799\n",
"10\t-0.506496\n",
"11\t0.292144\n",
"12\t0.026577\n",
"13\t0.031423\n",
"14\t0.065403\n",
"15\t0.061871\n",
"16\t0.061769\n",
"17\t0.022987\n",
"18\t0.022987\n",
"19\t0.022987\n",
"20\t0.026577\n",
"21\t0.031423\n",
"22\t0.062142\n",
"\n",
"S E T T I N G U P C A L C U L A T I O N S\n",
"\n",
"SETTING UP BOND CALCULATIONS...\n",
"SETTING UP ANGLE CALCULATIONS...\n",
"SETTING UP TORSION CALCULATIONS...\n",
"SETTING UP IMPROPER TORSION CALCULATIONS...\n",
"SETTING UP VAN DER WAALS CALCULATIONS...\n",
"SETTING UP ELECTROSTATIC CALCULATIONS...\n",
"\n",
"S T E E P E S T D E S C E N T\n",
"\n",
"STEPS = 2500\n",
"\n",
"STEP n E(n) E(n-1) \n",
"------------------------------------\n",
" 0 48.723 ----\n",
" 10 34.66977 35.19945\n",
" 20 30.99135 31.27220\n",
" 30 28.75939 28.94596\n",
" 40 27.18696 27.32449\n",
" 50 25.98408 26.09235\n",
" 60 25.01360 25.10261\n",
" 70 24.20264 24.27795\n",
" 80 23.50860 23.57362\n",
" 90 22.90429 22.96128\n",
" 100 22.37106 22.42162\n",
" 110 21.89546 21.94073\n",
" 120 21.46827 21.50901\n",
" 130 21.08181 21.11890\n",
" 140 20.72831 20.76234\n",
" 150 20.40289 20.43430\n",
" 160 20.10170 20.13083\n",
" 170 19.82166 19.84879\n",
" 180 19.56025 19.58562\n",
" 190 19.31545 19.33924\n",
" 200 19.08557 19.10794\n",
" 210 18.86924 18.89031\n",
" 220 18.66528 18.68516\n",
" 230 18.47270 18.49148\n",
" 240 18.29064 18.30840\n",
" 250 18.11835 18.13517\n",
" 260 17.95518 17.97111\n",
" 270 17.80053 17.81563\n",
" 280 17.65387 17.66819\n",
" 290 17.51471 17.52831\n",
" 300 17.38262 17.39553\n",
" 310 17.25718 17.26944\n",
" 320 17.13802 17.14967\n",
" 330 17.02479 17.03586\n",
" 340 16.91716 16.92768\n",
" 350 16.81482 16.82483\n",
" 360 16.71749 16.72701\n",
" 370 16.62491 16.63396\n",
" 380 16.53681 16.54543\n",
" 390 16.45297 16.46117\n",
" 400 16.37316 16.38097\n",
" 410 16.29717 16.30460\n",
" 420 16.22481 16.23189\n",
" 430 16.15588 16.16263\n",
" 440 16.09023 16.09665\n",
" 450 16.02767 16.03379\n",
" 460 15.96806 15.97389\n",
" 470 15.91124 15.91681\n",
" 480 15.85709 15.86239\n",
" 490 15.80546 15.81051\n",
" 500 15.75623 15.76105\n",
" 510 15.70929 15.71389\n",
" 520 15.66452 15.66891\n",
" 530 15.62182 15.62600\n",
" 540 15.58109 15.58508\n",
" 550 15.54223 15.54604\n",
" 560 15.50515 15.50879\n",
" 570 15.46978 15.47324\n",
" 580 15.43601 15.43932\n",
" 590 15.40379 15.40695\n",
" 600 15.37304 15.37605\n",
" 610 15.34369 15.34656\n",
" 620 15.31566 15.31841\n",
" 630 15.28891 15.29153\n",
" 640 15.26336 15.26587\n",
" 650 15.23897 15.24136\n",
" 660 15.21568 15.21797\n",
" 670 15.19344 15.19562\n",
" 680 15.17220 15.17428\n",
" 690 15.15191 15.15390\n",
" 700 15.13252 15.13442\n",
" 710 15.11401 15.11582\n",
" 720 15.09632 15.09805\n",
" 730 15.07942 15.08107\n",
" 740 15.06326 15.06485\n",
" 750 15.04783 15.04934\n",
" 760 15.03308 15.03452\n",
" 770 15.01898 15.02036\n",
" 780 15.00550 15.00682\n",
" 790 14.99261 14.99387\n",
" 800 14.98029 14.98150\n",
" 810 14.96850 14.96966\n",
" 820 14.95723 14.95834\n",
" 830 14.94645 14.94751\n",
" 840 14.93614 14.93715\n",
" 850 14.92627 14.92724\n",
" 860 14.91682 14.91775\n",
" 870 14.90778 14.90867\n",
" 880 14.89912 14.89997\n",
" 890 14.89084 14.89165\n",
" 900 14.88290 14.88368\n",
" 910 14.87529 14.87604\n",
" 920 14.86801 14.86872\n",
" 930 14.86102 14.86171\n",
" 940 14.85433 14.85498\n",
" 950 14.84790 14.84853\n",
" 960 14.84174 14.84235\n",
" 970 14.83583 14.83641\n",
" 980 14.83016 14.83071\n",
" 990 14.82471 14.82524\n",
" 1000 14.81947 14.81999\n",
" 1010 14.81444 14.81494\n",
" 1020 14.80960 14.81008\n",
" 1030 14.80495 14.80541\n",
" 1040 14.80047 14.80091\n",
" 1050 14.79616 14.79658\n",
" 1060 14.79200 14.79241\n",
" 1070 14.78800 14.78839\n",
" 1080 14.78414 14.78452\n",
" 1090 14.78041 14.78078\n",
" 1100 14.77681 14.77716\n",
" 1110 14.77332 14.77367\n",
" 1120 14.76996 14.77029\n",
" 1130 14.76670 14.76702\n",
" 1140 14.76354 14.76385\n",
" 1150 14.76074 14.76094\n",
" 1160 14.75918 14.75933\n",
" 1170 14.75775 14.75789\n",
" 1180 14.75635 14.75649\n",
" 1190 14.75499 14.75512\n",
" 1200 14.75365 14.75379\n",
" 1210 14.75235 14.75248\n",
" 1220 14.75107 14.75120\n",
" 1230 14.74983 14.74995\n",
" 1240 14.74861 14.74873\n",
" 1250 14.74741 14.74753\n",
" 1260 14.74624 14.74636\n",
" 1270 14.74510 14.74521\n",
" 1280 14.74398 14.74409\n",
" 1290 14.74288 14.74299\n",
" 1300 14.74180 14.74191\n",
" 1310 14.74075 14.74085\n",
" 1320 14.73971 14.73981\n",
" 1330 14.73870 14.73880\n",
" 1340 14.73770 14.73780\n",
" 1350 14.73672 14.73682\n",
" 1360 14.73576 14.73585\n",
" 1370 14.73481 14.73491\n",
" 1380 14.73388 14.73398\n",
" 1390 14.73297 14.73306\n",
" 1400 14.73207 14.73216\n",
" 1410 14.73119 14.73127\n",
" 1420 14.73032 14.73040\n",
" 1430 14.72946 14.72954\n",
" 1440 14.72861 14.72870\n",
" 1450 14.72778 14.72786\n",
" 1460 14.72696 14.72704\n",
" 1470 14.72615 14.72623\n",
" 1480 14.72535 14.72543\n",
" 1490 14.72456 14.72464\n",
" 1500 14.72378 14.72386\n",
" 1510 14.72305 14.72311\n",
" 1520 14.72263 14.72267\n",
" 1530 14.72225 14.72229\n",
" 1540 14.72188 14.72192\n",
" 1550 14.72151 14.72155\n",
" 1560 14.72115 14.72119\n",
" 1570 14.72079 14.72083\n",
" 1580 14.72044 14.72048\n",
" 1590 14.72010 14.72013\n",
" 1600 14.71975 14.71979\n",
" 1610 14.71942 14.71945\n",
" 1620 14.71908 14.71912\n",
" 1630 14.71876 14.71879\n",
" 1640 14.71843 14.71846\n",
" 1650 14.71811 14.71814\n",
" 1660 14.71780 14.71783\n",
" 1670 14.71748 14.71752\n",
" 1680 14.71718 14.71721\n",
" 1690 14.71687 14.71690\n",
" 1700 14.71657 14.71660\n",
" 1710 14.71628 14.71631\n",
" 1720 14.71598 14.71601\n",
" 1730 14.71569 14.71572\n",
" 1740 14.71541 14.71544\n",
" 1750 14.71513 14.71515\n",
" 1760 14.71485 14.71487\n",
" 1770 14.71457 14.71460\n",
" 1780 14.71430 14.71432\n",
" 1790 14.71403 14.71405\n",
" 1800 14.71376 14.71379\n",
" 1810 14.71350 14.71352\n",
" 1820 14.71324 14.71326\n",
" 1830 14.71298 14.71300\n",
" 1840 14.71272 14.71275\n",
" 1850 14.71247 14.71249\n",
" 1860 14.71227 14.71229\n",
" 1870 14.71214 14.71216\n",
" 1880 14.71202 14.71203\n",
" 1890 14.71189 14.71190\n",
" 1900 14.71177 14.71178\n",
" 1910 14.71164 14.71166\n",
" 1920 14.71152 14.71153\n",
" 1930 14.71140 14.71142\n",
" 1940 14.71128 14.71130\n",
" 1950 14.71117 14.71118\n",
" 1960 14.71105 14.71107\n",
" 1970 14.71094 14.71095\n",
" 1980 14.71083 14.71084\n",
" 1990 14.71072 14.71073\n",
" 2000 14.71061 14.71062\n",
" 2010 14.71051 14.71052\n",
" 2020 14.71040 14.71041\n",
" 2030 14.71030 14.71031\n",
" 2040 14.71020 14.71021\n",
" 2050 14.71010 14.71011\n",
" 2060 14.71000 14.71001\n",
" 2070 14.70990 14.70991\n",
" 2080 14.70980 14.70981\n",
" 2090 14.70971 14.70972\n",
" 2100 14.70962 14.70962\n",
" 2110 14.70952 14.70953\n",
" 2120 14.70944 14.70944\n",
" 2130 14.70935 14.70936\n",
" 2140 14.70926 14.70927\n",
" 2150 14.70918 14.70918\n",
" 2160 14.70909 14.70910\n",
" 2170 14.70901 14.70902\n",
" 2180 14.70893 14.70893\n",
" 2190 14.70885 14.70885\n",
" 2200 14.70877 14.70877\n",
" 2210 14.70869 14.70870\n",
" 2220 14.70861 14.70862\n",
" 2230 14.70853 14.70854\n",
" 2240 14.70847 14.70847\n",
" 2250 14.70842 14.70842\n",
" 2260 14.70838 14.70838\n",
" 2270 14.70834 14.70834\n",
" 2280 14.70830 14.70830\n",
" 2290 14.70826 14.70826\n",
" 2300 14.70822 14.70823\n",
" 2310 14.70818 14.70819\n",
" 2320 14.70815 14.70815\n",
" 2330 14.70811 14.70811\n",
" 2340 14.70807 14.70808\n",
" 2350 14.70804 14.70804\n",
" 2360 14.70800 14.70801\n",
" 2370 14.70797 14.70797\n",
" 2380 14.70793 14.70794\n",
" 2390 14.70790 14.70790\n",
" 2400 14.70787 14.70787\n",
" 2410 14.70783 14.70784\n",
" 2420 14.70780 14.70780\n",
" 2430 14.70777 14.70777\n",
" 2440 14.70774 14.70774\n",
" 2450 14.70771 14.70771\n",
" 2460 14.70768 14.70768\n",
" 2470 14.70764 14.70765\n",
" 2480 14.70761 14.70762\n",
" 2490 14.70759 14.70759\n",
" 2500 14.70756 14.70756\n",
"Time: 0.173925seconds. Iterations per second: 14379.8\n",
"\n",
"2025-01-03 16:01:28,619 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/fba7f47f-7f77-4aff-9402-49296ced2556']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 8,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"babel_minimize(input_path=output_reduce_h,\n",
" output_path=output_babel_min,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 9,
"id": "9c28c2dd-6c74-4b48-be0d-f503f5bdab53",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:29.287881Z",
"iopub.status.busy": "2025-01-03T07:01:29.287716Z",
"iopub.status.idle": "2025-01-03T07:01:29.309611Z",
"shell.execute_reply": "2025-01-03T07:01:29.308711Z",
"shell.execute_reply.started": "2025-01-03T07:01:29.287867Z"
}
},
"outputs": [
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "38a0443d37cd43b0b8aafc1d8e847cbd",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"HBox(children=(NGLWidget(), NGLWidget(), NGLWidget()))"
]
},
"execution_count": 9,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# Show different structures generated (for comparison)\n",
"\n",
"view1 = nglview.show_structure_file(ligandFile)\n",
"view1.add_representation(repr_type='ball+stick')\n",
"view1._remote_call('setSize', target='Widget', args=['350px','400px'])\n",
"view1.camera='orthographic'\n",
"view1\n",
"view2 = nglview.show_structure_file(output_reduce_h)\n",
"view2.add_representation(repr_type='ball+stick')\n",
"view2._remote_call('setSize', target='Widget', args=['350px','400px'])\n",
"view2.camera='orthographic'\n",
"view2\n",
"view3 = nglview.show_structure_file(output_babel_min)\n",
"view3.add_representation(repr_type='ball+stick')\n",
"view3._remote_call('setSize', target='Widget', args=['350px','400px'])\n",
"view3.camera='orthographic'\n",
"view3\n",
"ipywidgets.HBox([view1, view2, view3])"
]
},
{
"cell_type": "code",
"execution_count": 10,
"id": "0577a87f-a3d1-40af-8d07-05dfdf308b5b",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:30.444946Z",
"iopub.status.busy": "2025-01-03T07:01:30.444798Z",
"iopub.status.idle": "2025-01-03T07:01:31.123325Z",
"shell.execute_reply": "2025-01-03T07:01:31.123050Z",
"shell.execute_reply.started": "2025-01-03T07:01:30.444936Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:30,455 [MainThread ] [INFO ] Executing biobb_chemistry.acpype.acpype_params_gmx Version: 4.2.1\n",
"2025-01-03 16:01:30,456 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/JZ4.H.min.mol2 to /home/iwatobipen/dev/sandbox/biobb_demo/a3bae65c-f4e0-4eb6-85bc-88f1dbb70e0c\n",
"2025-01-03 16:01:30,456 [MainThread ] [INFO ] acpype -i /home/iwatobipen/dev/sandbox/biobb_demo/a3bae65c-f4e0-4eb6-85bc-88f1dbb70e0c/JZ4.H.min.mol2 -b JZ4params.TnYgMj -n 0\n",
"\n",
"2025-01-03 16:01:31,119 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:31,119 [MainThread ] [INFO ] ==========================================================================\n",
"| ACPYPE: AnteChamber PYthon Parser interfacE v. 2022.6.6 (c) 2025 AWSdS |\n",
"==========================================================================\n",
"==> ... charge set to 0\n",
"==> Executing Antechamber...\n",
"==> * Antechamber OK *\n",
"==> * Parmchk OK *\n",
"==> Executing Tleap...\n",
"==> * Tleap OK *\n",
"==> Removing temporary files...\n",
"==> Using OpenBabel v.3.1.0\n",
"\n",
"==> Writing NEW PDB file\n",
"\n",
"==> Writing CNS/XPLOR files\n",
"\n",
"==> Writing GROMACS files\n",
"\n",
"==> Disambiguating lower and uppercase atomtypes in GMX top file, even if identical.\n",
"\n",
"==> Writing GMX dihedrals for GMX 4.5 and higher.\n",
"\n",
"==> Writing CHARMM files\n",
"\n",
"==> Writing pickle file JZ4params.TnYgMj.pkl\n",
"==> Removing temporary files...\n",
"Total time of execution: 1s\n",
"\n",
"2025-01-03 16:01:31,120 [MainThread ] [INFO ] File JZ4params.top succesfully created\n",
"2025-01-03 16:01:31,121 [MainThread ] [INFO ] File JZ4params.gro succesfully created\n",
"2025-01-03 16:01:31,121 [MainThread ] [INFO ] File JZ4params.itp succesfully created\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 10,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from biobb_chemistry.acpype.acpype_params_gmx import acpype_params_gmx\n",
"\n",
"output_acpype_gro = ligandCode+'params.gro'\n",
"output_acpype_itp = ligandCode+'params.itp'\n",
"output_acpype_top = ligandCode+'params.top'\n",
"output_acpype = ligandCode+'params'\n",
"prop = {\n",
" 'basename':output_acpype,\n",
" 'charge': mol_charge\n",
"}\n",
"\n",
"# Create and launch bb\n",
"\n",
"acpype_params_gmx(input_path=output_babel_min, \n",
" output_path_gro=output_acpype_gro,\n",
" output_path_itp=output_acpype_itp,\n",
" output_path_top=output_acpype_top,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 11,
"id": "6f280bf3-9f07-4dfa-b0d1-f382bb07ba1c",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:31.251690Z",
"iopub.status.busy": "2025-01-03T07:01:31.251533Z",
"iopub.status.idle": "2025-01-03T07:01:31.290545Z",
"shell.execute_reply": "2025-01-03T07:01:31.290275Z",
"shell.execute_reply.started": "2025-01-03T07:01:31.251680Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:31,277 [MainThread ] [INFO ] Executing biobb_gromacs.gromacs.make_ndx Version: 4.2.0\n",
"2025-01-03 16:01:31,278 [MainThread ] [INFO ] Copy: JZ4params.gro to /home/iwatobipen/dev/sandbox/biobb_demo/da10ca01-2369-4ee8-a588-d1b72e0a3aec\n",
"2025-01-03 16:01:31,278 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/34bc8070-f7ab-493b-aaeb-185be138c560.stdin to /home/iwatobipen/dev/sandbox/biobb_demo/da10ca01-2369-4ee8-a588-d1b72e0a3aec\n",
"2025-01-03 16:01:31,279 [MainThread ] [INFO ] gmx -nobackup -nocopyright make_ndx -f /home/iwatobipen/dev/sandbox/biobb_demo/da10ca01-2369-4ee8-a588-d1b72e0a3aec/JZ4params.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/da10ca01-2369-4ee8-a588-d1b72e0a3aec/JZ4_index.ndx < /home/iwatobipen/dev/sandbox/biobb_demo/da10ca01-2369-4ee8-a588-d1b72e0a3aec/34bc8070-f7ab-493b-aaeb-185be138c560.stdin\n",
"\n",
"2025-01-03 16:01:31,287 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:31,288 [MainThread ] [INFO ] Going to read 0 old index file(s)\n",
"Analysing residue names:\n",
"There are: 1 Other residues\n",
"Analysing residues not classified as Protein/DNA/RNA/Water and splitting into groups...\n",
"\n",
" 0 System : 22 atoms\n",
" 1 Other : 22 atoms\n",
" 2 JZ4 : 22 atoms\n",
"\n",
" nr : group '!': not 'name' nr name 'splitch' nr Enter: list groups\n",
" 'a': atom '&': and 'del' nr 'splitres' nr 'l': list residues\n",
" 't': atom type '|': or 'keep' nr 'splitat' nr 'h': help\n",
" 'r': residue 'res' nr 'chain' char\n",
" \"name\": group 'case': case sensitive 'q': save and quit\n",
" 'ri': residue index\n",
"\n",
"> \n",
"Copied index group 0 'System'\n",
"Found 12 atoms with name H*\n",
"Complemented group: 10 atoms\n",
"Merged two groups with AND: 22 10 -> 10\n",
"\n",
"> \n",
"\n",
"2025-01-03 16:01:31,288 [MainThread ] [INFO ] :-) GROMACS - gmx make_ndx, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx -nobackup -nocopyright make_ndx -f /home/iwatobipen/dev/sandbox/biobb_demo/da10ca01-2369-4ee8-a588-d1b72e0a3aec/JZ4params.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/da10ca01-2369-4ee8-a588-d1b72e0a3aec/JZ4_index.ndx\n",
"\n",
"\n",
"Reading structure file\n",
"\n",
"GROMACS reminds you: \"I removed all the lambda defaults so that users have to think!\" (Berk Hess)\n",
"\n",
"\n",
"2025-01-03 16:01:31,288 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/da10ca01-2369-4ee8-a588-d1b72e0a3aec', '/home/iwatobipen/dev/sandbox/biobb_demo/34bc8070-f7ab-493b-aaeb-185be138c560.stdin']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 11,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from biobb_gromacs.gromacs.make_ndx import make_ndx\n",
"\n",
"# Create prop dict and inputs/outputs\n",
"output_ligand_ndx = ligandCode+'_index.ndx'\n",
"prop = {\n",
" 'selection': \"0 & ! a H*\"\n",
"}\n",
"\n",
"# Create and launch bb\n",
"make_ndx(input_structure_path=output_acpype_gro,\n",
" output_ndx_path=output_ligand_ndx,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 12,
"id": "a196cce8-d51e-4d43-9c06-95248073ed46",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:32.036815Z",
"iopub.status.busy": "2025-01-03T07:01:32.036603Z",
"iopub.status.idle": "2025-01-03T07:01:32.078829Z",
"shell.execute_reply": "2025-01-03T07:01:32.078519Z",
"shell.execute_reply.started": "2025-01-03T07:01:32.036803Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:32,064 [MainThread ] [INFO ] Executing biobb_gromacs.gromacs.make_ndx Version: 4.2.0\n",
"2025-01-03 16:01:32,065 [MainThread ] [INFO ] Copy: JZ4params.gro to /home/iwatobipen/dev/sandbox/biobb_demo/78c839c5-c47b-4dd7-90c0-4a80bbe55106\n",
"2025-01-03 16:01:32,065 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/9a3fc67a-6668-462f-b2ed-650a1d943043.stdin to /home/iwatobipen/dev/sandbox/biobb_demo/78c839c5-c47b-4dd7-90c0-4a80bbe55106\n",
"2025-01-03 16:01:32,066 [MainThread ] [INFO ] gmx -nobackup -nocopyright make_ndx -f /home/iwatobipen/dev/sandbox/biobb_demo/78c839c5-c47b-4dd7-90c0-4a80bbe55106/JZ4params.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/78c839c5-c47b-4dd7-90c0-4a80bbe55106/JZ4_index.ndx < /home/iwatobipen/dev/sandbox/biobb_demo/78c839c5-c47b-4dd7-90c0-4a80bbe55106/9a3fc67a-6668-462f-b2ed-650a1d943043.stdin\n",
"\n",
"2025-01-03 16:01:32,075 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:32,075 [MainThread ] [INFO ] Going to read 0 old index file(s)\n",
"Analysing residue names:\n",
"There are: 1 Other residues\n",
"Analysing residues not classified as Protein/DNA/RNA/Water and splitting into groups...\n",
"\n",
" 0 System : 22 atoms\n",
" 1 Other : 22 atoms\n",
" 2 JZ4 : 22 atoms\n",
"\n",
" nr : group '!': not 'name' nr name 'splitch' nr Enter: list groups\n",
" 'a': atom '&': and 'del' nr 'splitres' nr 'l': list residues\n",
" 't': atom type '|': or 'keep' nr 'splitat' nr 'h': help\n",
" 'r': residue 'res' nr 'chain' char\n",
" \"name\": group 'case': case sensitive 'q': save and quit\n",
" 'ri': residue index\n",
"\n",
"> \n",
"Copied index group 0 'System'\n",
"Found 12 atoms with name H*\n",
"Complemented group: 10 atoms\n",
"Merged two groups with AND: 22 10 -> 10\n",
"\n",
"> \n",
"\n",
"2025-01-03 16:01:32,075 [MainThread ] [INFO ] :-) GROMACS - gmx make_ndx, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx -nobackup -nocopyright make_ndx -f /home/iwatobipen/dev/sandbox/biobb_demo/78c839c5-c47b-4dd7-90c0-4a80bbe55106/JZ4params.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/78c839c5-c47b-4dd7-90c0-4a80bbe55106/JZ4_index.ndx\n",
"\n",
"\n",
"Reading structure file\n",
"\n",
"GROMACS reminds you: \"If mathematical analysis should ever hold a prominent place in chemistry - an aberration which is happily almost impossible - it would occasion a rapid and widespread degeneration of that science.\" (Aguste Comte, 1830)\n",
"\n",
"\n",
"2025-01-03 16:01:32,076 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/78c839c5-c47b-4dd7-90c0-4a80bbe55106', '/home/iwatobipen/dev/sandbox/biobb_demo/9a3fc67a-6668-462f-b2ed-650a1d943043.stdin']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 12,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# MakeNdx: Creating index file with a new group (small molecule heavy atoms)\n",
"from biobb_gromacs.gromacs.make_ndx import make_ndx\n",
"\n",
"# Create prop dict and inputs/outputs\n",
"output_ligand_ndx = ligandCode+'_index.ndx'\n",
"prop = {\n",
" 'selection': \"0 & ! a H*\"\n",
"}\n",
"\n",
"# Create and launch bb\n",
"make_ndx(input_structure_path=output_acpype_gro,\n",
" output_ndx_path=output_ligand_ndx,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 13,
"id": "e2ce3d66-ef04-4bb7-9b6c-b88a3fcaf513",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:34.271037Z",
"iopub.status.busy": "2025-01-03T07:01:34.270862Z",
"iopub.status.idle": "2025-01-03T07:01:34.315108Z",
"shell.execute_reply": "2025-01-03T07:01:34.314855Z",
"shell.execute_reply.started": "2025-01-03T07:01:34.271022Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:34,299 [MainThread ] [INFO ] Executing biobb_gromacs.gromacs.genrestr Version: 4.2.0\n",
"2025-01-03 16:01:34,300 [MainThread ] [INFO ] Copy: JZ4params.gro to /home/iwatobipen/dev/sandbox/biobb_demo/d3752b82-8cec-4e42-a2d9-ef9cfb2e02ab\n",
"2025-01-03 16:01:34,300 [MainThread ] [INFO ] Copy: JZ4_index.ndx to /home/iwatobipen/dev/sandbox/biobb_demo/d3752b82-8cec-4e42-a2d9-ef9cfb2e02ab\n",
"2025-01-03 16:01:34,301 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/e7c5a5e2-2159-4957-bd0d-2f574062be7b.stdin to /home/iwatobipen/dev/sandbox/biobb_demo/d3752b82-8cec-4e42-a2d9-ef9cfb2e02ab\n",
"2025-01-03 16:01:34,302 [MainThread ] [INFO ] gmx -nobackup -nocopyright genrestr -f /home/iwatobipen/dev/sandbox/biobb_demo/d3752b82-8cec-4e42-a2d9-ef9cfb2e02ab/JZ4params.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/d3752b82-8cec-4e42-a2d9-ef9cfb2e02ab/JZ4_posres.itp -fc 1000 1000 1000 -n /home/iwatobipen/dev/sandbox/biobb_demo/d3752b82-8cec-4e42-a2d9-ef9cfb2e02ab/JZ4_index.ndx < /home/iwatobipen/dev/sandbox/biobb_demo/d3752b82-8cec-4e42-a2d9-ef9cfb2e02ab/e7c5a5e2-2159-4957-bd0d-2f574062be7b.stdin\n",
"\n",
"2025-01-03 16:01:34,311 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:34,312 [MainThread ] [INFO ] Select group to position restrain\n",
"Selected 3: 'System_&_!H*'\n",
"\n",
"2025-01-03 16:01:34,312 [MainThread ] [INFO ] :-) GROMACS - gmx genrestr, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx -nobackup -nocopyright genrestr -f /home/iwatobipen/dev/sandbox/biobb_demo/d3752b82-8cec-4e42-a2d9-ef9cfb2e02ab/JZ4params.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/d3752b82-8cec-4e42-a2d9-ef9cfb2e02ab/JZ4_posres.itp -fc 1000 1000 1000 -n /home/iwatobipen/dev/sandbox/biobb_demo/d3752b82-8cec-4e42-a2d9-ef9cfb2e02ab/JZ4_index.ndx\n",
"\n",
"\n",
"Reading structure file\n",
"Group 0 ( System) has 22 elements\n",
"Group 1 ( Other) has 22 elements\n",
"Group 2 ( JZ4) has 22 elements\n",
"Group 3 ( System_&_!H*) has 10 elements\n",
"Select a group: \n",
"GROMACS reminds you: \"Naive you are if you believe life favours those who aren't naive.\" (Piet Hein)\n",
"\n",
"\n",
"2025-01-03 16:01:34,313 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/d3752b82-8cec-4e42-a2d9-ef9cfb2e02ab', '/home/iwatobipen/dev/sandbox/biobb_demo/e7c5a5e2-2159-4957-bd0d-2f574062be7b.stdin']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 13,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# Genrestr: Generating the position restraints file\n",
"from biobb_gromacs.gromacs.genrestr import genrestr\n",
"\n",
"# Create prop dict and inputs/outputs\n",
"output_restraints_top = ligandCode+'_posres.itp'\n",
"prop = {\n",
" 'force_constants': \"1000 1000 1000\",\n",
" 'restrained_group': \"System_&_!H*\"\n",
"}\n",
"\n",
"# Create and launch bb\n",
"genrestr(input_structure_path=output_acpype_gro,\n",
" input_ndx_path=output_ligand_ndx,\n",
" output_itp_path=output_restraints_top,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 14,
"id": "c5c5873a-3d0b-41a7-81a9-a8f739d16011",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:35.012358Z",
"iopub.status.busy": "2025-01-03T07:01:35.012074Z",
"iopub.status.idle": "2025-01-03T07:01:35.065924Z",
"shell.execute_reply": "2025-01-03T07:01:35.065627Z",
"shell.execute_reply.started": "2025-01-03T07:01:35.012344Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:35,024 [MainThread ] [INFO ] Executing biobb_analysis.gromacs.gmx_trjconv_str Version: 4.2.0\n",
"2025-01-03 16:01:35,025 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_pdb2gmx.gro to /home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673\n",
"2025-01-03 16:01:35,026 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_pdb2gmx.gro to /home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673\n",
"2025-01-03 16:01:35,026 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/4fe7dbfd-dcf3-41fd-b05f-309a952cdc1f.stdin to /home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673\n",
"2025-01-03 16:01:35,027 [MainThread ] [INFO ] gmx trjconv -f /home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673/3HTB_pdb2gmx.gro -s /home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673/3HTB_pdb2gmx.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673/3HTB_JZ4comlex_H.pdb -nocenter < /home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673/4fe7dbfd-dcf3-41fd-b05f-309a952cdc1f.stdin\n",
"\n",
"2025-01-03 16:01:35,044 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:35,045 [MainThread ] [INFO ] Note that major changes are planned in future for trjconv, to improve usability and utility.\n",
"Select group for output\n",
"Selected 0: 'System'\n",
"\n",
"2025-01-03 16:01:35,045 [MainThread ] [INFO ] :-) GROMACS - gmx trjconv, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx trjconv -f /home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673/3HTB_pdb2gmx.gro -s /home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673/3HTB_pdb2gmx.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673/3HTB_JZ4comlex_H.pdb -nocenter\n",
"\n",
"Will write pdb: Protein data bank file\n",
"Group 0 ( System) has 2614 elements\n",
"Group 1 ( Protein) has 2614 elements\n",
"Group 2 ( Protein-H) has 1301 elements\n",
"Group 3 ( C-alpha) has 163 elements\n",
"Group 4 ( Backbone) has 489 elements\n",
"Group 5 ( MainChain) has 653 elements\n",
"Group 6 ( MainChain+Cb) has 805 elements\n",
"Group 7 ( MainChain+H) has 815 elements\n",
"Group 8 ( SideChain) has 1799 elements\n",
"Group 9 ( SideChain-H) has 648 elements\n",
"Select a group: Reading frames from gro file 'GROup of MAchos and Cynical Suckers', 2614 atoms.\n",
"Reading frame 0 time 0.000 \n",
"Precision of /home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673/3HTB_pdb2gmx.gro is 0.001 (nm)\n",
"Last frame 0 time 0.000 \n",
" -> frame 0 time 0.000 \n",
"Last written: frame 0 time 0.000\n",
"\n",
"\n",
"GROMACS reminds you: \"Hang On to Your Ego\" (F. Black)\n",
"\n",
"\n",
"2025-01-03 16:01:35,046 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/a705751e-d465-4b2c-8e48-eada670a3673', '/home/iwatobipen/dev/sandbox/biobb_demo/4fe7dbfd-dcf3-41fd-b05f-309a952cdc1f.stdin']\n",
"2025-01-03 16:01:35,047 [MainThread ] [INFO ] Executing biobb_analysis.gromacs.gmx_trjconv_str Version: 4.2.0\n",
"2025-01-03 16:01:35,048 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/JZ4params.gro to /home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7\n",
"2025-01-03 16:01:35,048 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/JZ4params.gro to /home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7\n",
"2025-01-03 16:01:35,049 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/3a47a75f-2c7b-4506-8a8f-fc7c5e5607f2.stdin to /home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7\n",
"2025-01-03 16:01:35,049 [MainThread ] [INFO ] gmx trjconv -f /home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7/JZ4params.gro -s /home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7/JZ4params.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7/JZ4_complex_H.pdb -nocenter < /home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7/3a47a75f-2c7b-4506-8a8f-fc7c5e5607f2.stdin\n",
"\n",
"2025-01-03 16:01:35,059 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:35,059 [MainThread ] [INFO ] Note that major changes are planned in future for trjconv, to improve usability and utility.\n",
"Select group for output\n",
"Selected 0: 'System'\n",
"\n",
"2025-01-03 16:01:35,060 [MainThread ] [INFO ] :-) GROMACS - gmx trjconv, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx trjconv -f /home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7/JZ4params.gro -s /home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7/JZ4params.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7/JZ4_complex_H.pdb -nocenter\n",
"\n",
"Will write pdb: Protein data bank file\n",
"Group 0 ( System) has 22 elements\n",
"Group 1 ( Other) has 22 elements\n",
"Group 2 ( JZ4) has 22 elements\n",
"Select a group: Reading frames from gro file 'JZ4params_GMX.gro created by acpype (v: 2022.6.6) on Fri Jan 3 16:01:30 2025', 22 atoms.\n",
"Reading frame 0 time 0.000 \n",
"Precision of /home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7/JZ4params.gro is 0.001 (nm)\n",
"Last frame 0 time 0.000 \n",
" -> frame 0 time 0.000 \n",
"Last written: frame 0 time 0.000\n",
"\n",
"\n",
"GROMACS reminds you: \"Hang On to Your Ego\" (F. Black)\n",
"\n",
"\n",
"2025-01-03 16:01:35,060 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/99045687-0eb0-477b-b9ed-625a66d36df7', '/home/iwatobipen/dev/sandbox/biobb_demo/3a47a75f-2c7b-4506-8a8f-fc7c5e5607f2.stdin']\n",
"2025-01-03 16:01:35,061 [MainThread ] [INFO ] Executing biobb_structure_utils.utils.cat_pdb Version: 4.2.0\n",
"2025-01-03 16:01:35,062 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_JZ4comlex_H.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/81e7320d-0b04-4fa7-aaf1-2ed3b0bc3f30\n",
"2025-01-03 16:01:35,062 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/JZ4_complex_H.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/81e7320d-0b04-4fa7-aaf1-2ed3b0bc3f30\n",
"2025-01-03 16:01:35,063 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/81e7320d-0b04-4fa7-aaf1-2ed3b0bc3f30']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 14,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from biobb_analysis.gromacs.gmx_trjconv_str import gmx_trjconv_str\n",
"from biobb_structure_utils.utils.cat_pdb import cat_pdb\n",
"\n",
"proteinFile_H = pdbCode +'_'+ligandCode+'comlex_H.pdb'\n",
"prop = {'selection':'System'}\n",
"gmx_trjconv_str(input_structure_path=output_pdb2gmx_gro,\n",
" input_top_path=output_pdb2gmx_gro,\n",
" output_str_path=proteinFile_H,\n",
" properties=prop)\n",
"\n",
"ligandFile_H = ligandCode+'_complex_H.pdb'\n",
"prop = {\n",
" 'selection':'System'\n",
"}\n",
"gmx_trjconv_str(input_structure_path=output_acpype_gro,\n",
" input_top_path=output_acpype_gro,\n",
" output_str_path=ligandFile_H,\n",
" properties=prop)\n",
"\n",
"complexFile_H = pdbCode+'_'+ligandCode+'_H.pdb'\n",
"cat_pdb(input_structure1=proteinFile_H,\n",
" input_structure2=ligandFile_H,\n",
" output_structure_path=complexFile_H)"
]
},
{
"cell_type": "code",
"execution_count": 15,
"id": "ad191548-7944-411e-8583-725c2662d6ab",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:35.585033Z",
"iopub.status.busy": "2025-01-03T07:01:35.584875Z",
"iopub.status.idle": "2025-01-03T07:01:35.627003Z",
"shell.execute_reply": "2025-01-03T07:01:35.626611Z",
"shell.execute_reply.started": "2025-01-03T07:01:35.585018Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:35,587 [MainThread ] [INFO ] Executing biobb_analysis.gromacs.gmx_trjconv_str Version: 4.2.0\n",
"2025-01-03 16:01:35,588 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_pdb2gmx.gro to /home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546\n",
"2025-01-03 16:01:35,588 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_pdb2gmx.gro to /home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546\n",
"2025-01-03 16:01:35,589 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/8629aaf0-2536-4e73-8558-220ca47a980a.stdin to /home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546\n",
"2025-01-03 16:01:35,589 [MainThread ] [INFO ] gmx trjconv -f /home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546/3HTB_pdb2gmx.gro -s /home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546/3HTB_pdb2gmx.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546/3HTB_JZ4_complex_H.pdb -nocenter < /home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546/8629aaf0-2536-4e73-8558-220ca47a980a.stdin\n",
"\n",
"2025-01-03 16:01:35,604 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:35,604 [MainThread ] [INFO ] Note that major changes are planned in future for trjconv, to improve usability and utility.\n",
"Select group for output\n",
"Selected 0: 'System'\n",
"\n",
"2025-01-03 16:01:35,605 [MainThread ] [INFO ] :-) GROMACS - gmx trjconv, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx trjconv -f /home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546/3HTB_pdb2gmx.gro -s /home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546/3HTB_pdb2gmx.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546/3HTB_JZ4_complex_H.pdb -nocenter\n",
"\n",
"Will write pdb: Protein data bank file\n",
"Group 0 ( System) has 2614 elements\n",
"Group 1 ( Protein) has 2614 elements\n",
"Group 2 ( Protein-H) has 1301 elements\n",
"Group 3 ( C-alpha) has 163 elements\n",
"Group 4 ( Backbone) has 489 elements\n",
"Group 5 ( MainChain) has 653 elements\n",
"Group 6 ( MainChain+Cb) has 805 elements\n",
"Group 7 ( MainChain+H) has 815 elements\n",
"Group 8 ( SideChain) has 1799 elements\n",
"Group 9 ( SideChain-H) has 648 elements\n",
"Select a group: Reading frames from gro file 'GROup of MAchos and Cynical Suckers', 2614 atoms.\n",
"Reading frame 0 time 0.000 \n",
"Precision of /home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546/3HTB_pdb2gmx.gro is 0.001 (nm)\n",
"Last frame 0 time 0.000 \n",
" -> frame 0 time 0.000 \n",
"Last written: frame 0 time 0.000\n",
"\n",
"\n",
"GROMACS reminds you: \"Hang On to Your Ego\" (F. Black)\n",
"\n",
"\n",
"2025-01-03 16:01:35,606 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/57e9b279-161c-45df-bfc1-1811b712c546', '/home/iwatobipen/dev/sandbox/biobb_demo/8629aaf0-2536-4e73-8558-220ca47a980a.stdin']\n",
"2025-01-03 16:01:35,608 [MainThread ] [INFO ] Executing biobb_analysis.gromacs.gmx_trjconv_str Version: 4.2.0\n",
"2025-01-03 16:01:35,609 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/JZ4params.gro to /home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72\n",
"2025-01-03 16:01:35,609 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/JZ4params.gro to /home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72\n",
"2025-01-03 16:01:35,609 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/f34925cd-e928-453c-aa05-dda0b2710c28.stdin to /home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72\n",
"2025-01-03 16:01:35,610 [MainThread ] [INFO ] gmx trjconv -f /home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72/JZ4params.gro -s /home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72/JZ4params.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72/JZ4_complex_H.pdb -nocenter < /home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72/f34925cd-e928-453c-aa05-dda0b2710c28.stdin\n",
"\n",
"2025-01-03 16:01:35,619 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:35,620 [MainThread ] [INFO ] Note that major changes are planned in future for trjconv, to improve usability and utility.\n",
"Select group for output\n",
"Selected 0: 'System'\n",
"\n",
"2025-01-03 16:01:35,620 [MainThread ] [INFO ] :-) GROMACS - gmx trjconv, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx trjconv -f /home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72/JZ4params.gro -s /home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72/JZ4params.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72/JZ4_complex_H.pdb -nocenter\n",
"\n",
"Will write pdb: Protein data bank file\n",
"Group 0 ( System) has 22 elements\n",
"Group 1 ( Other) has 22 elements\n",
"Group 2 ( JZ4) has 22 elements\n",
"Select a group: Reading frames from gro file 'JZ4params_GMX.gro created by acpype (v: 2022.6.6) on Fri Jan 3 16:01:30 2025', 22 atoms.\n",
"Reading frame 0 time 0.000 \n",
"Precision of /home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72/JZ4params.gro is 0.001 (nm)\n",
"Last frame 0 time 0.000 \n",
" -> frame 0 time 0.000 \n",
"Last written: frame 0 time 0.000\n",
"\n",
"\n",
"GROMACS reminds you: \"Hang On to Your Ego\" (F. Black)\n",
"\n",
"\n",
"2025-01-03 16:01:35,621 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/8b128c11-3677-4de7-bc0c-80b5ddee0d72', '/home/iwatobipen/dev/sandbox/biobb_demo/f34925cd-e928-453c-aa05-dda0b2710c28.stdin']\n",
"2025-01-03 16:01:35,622 [MainThread ] [INFO ] Executing biobb_structure_utils.utils.cat_pdb Version: 4.2.0\n",
"2025-01-03 16:01:35,622 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_JZ4_complex_H.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/b3ca716f-6208-4cd7-9501-e8945a0fb67e\n",
"2025-01-03 16:01:35,623 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/JZ4_complex_H.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/b3ca716f-6208-4cd7-9501-e8945a0fb67e\n",
"2025-01-03 16:01:35,624 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/b3ca716f-6208-4cd7-9501-e8945a0fb67e']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 15,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# biobb analysis module\n",
"from biobb_analysis.gromacs.gmx_trjconv_str import gmx_trjconv_str\n",
"from biobb_structure_utils.utils.cat_pdb import cat_pdb\n",
"\n",
"# Convert gro (with hydrogens) to pdb (PROTEIN)\n",
"proteinFile_H = pdbCode+'_'+ligandCode+'_complex_H.pdb'\n",
"prop = {\n",
" 'selection' : 'System'\n",
"}\n",
"\n",
"# Create and launch bb\n",
"gmx_trjconv_str(input_structure_path=output_pdb2gmx_gro,\n",
" input_top_path=output_pdb2gmx_gro,\n",
" output_str_path=proteinFile_H, \n",
" properties=prop)\n",
"\n",
"# Convert gro (with hydrogens) to pdb (LIGAND)\n",
"ligandFile_H = ligandCode+'_complex_H.pdb'\n",
"prop = {\n",
" 'selection' : 'System'\n",
"}\n",
"\n",
"# Create and launch bb\n",
"gmx_trjconv_str(input_structure_path=output_acpype_gro,\n",
" input_top_path=output_acpype_gro,\n",
" output_str_path=ligandFile_H, \n",
" properties=prop)\n",
"\n",
"\n",
"# Concatenating both PDB files: Protein + Ligand\n",
"complexFile_H = pdbCode+'_'+ligandCode+'_H.pdb'\n",
"\n",
"# Create and launch bb\n",
"cat_pdb(input_structure1=proteinFile_H,\n",
" input_structure2=ligandFile_H,\n",
" output_structure_path=complexFile_H)\n",
"\n"
]
},
{
"cell_type": "code",
"execution_count": 16,
"id": "383e7a2b-8d97-4133-884f-96df53947bbc",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:37.747126Z",
"iopub.status.busy": "2025-01-03T07:01:37.746967Z",
"iopub.status.idle": "2025-01-03T07:01:37.782406Z",
"shell.execute_reply": "2025-01-03T07:01:37.782133Z",
"shell.execute_reply.started": "2025-01-03T07:01:37.747116Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:37,749 [MainThread ] [INFO ] Executing biobb_gromacs.gromacs_extra.append_ligand Version: 4.2.0\n",
"2025-01-03 16:01:37,758 [MainThread ] [INFO ] Extracting: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_pdb2gmx.top.zip\n",
"2025-01-03 16:01:37,758 [MainThread ] [INFO ] to:\n",
"2025-01-03 16:01:37,759 [MainThread ] [INFO ] ['a24737b9-84a2-4f72-9a98-6ee5096ac702/p2g.top', 'a24737b9-84a2-4f72-9a98-6ee5096ac702/posre.itp']\n",
"2025-01-03 16:01:37,759 [MainThread ] [INFO ] Unzipping: \n",
"2025-01-03 16:01:37,760 [MainThread ] [INFO ] 3HTB_pdb2gmx.top.zip\n",
"2025-01-03 16:01:37,760 [MainThread ] [INFO ] To: \n",
"2025-01-03 16:01:37,761 [MainThread ] [INFO ] a24737b9-84a2-4f72-9a98-6ee5096ac702/p2g.top\n",
"2025-01-03 16:01:37,761 [MainThread ] [INFO ] a24737b9-84a2-4f72-9a98-6ee5096ac702/posre.itp\n",
"2025-01-03 16:01:37,773 [MainThread ] [INFO ] Compressing topology to: 3HTB_JZ4_complex.top.zip\n",
"2025-01-03 16:01:37,773 [MainThread ] [INFO ] Ignored file a24737b9-84a2-4f72-9a98-6ee5096ac702/amber99sb-ildn.ff/forcefield.itp\n",
"2025-01-03 16:01:37,777 [MainThread ] [INFO ] Ignored file a24737b9-84a2-4f72-9a98-6ee5096ac702/amber99sb-ildn.ff/spce.itp\n",
"2025-01-03 16:01:37,777 [MainThread ] [INFO ] Ignored file a24737b9-84a2-4f72-9a98-6ee5096ac702/amber99sb-ildn.ff/ions.itp\n",
"2025-01-03 16:01:37,778 [MainThread ] [INFO ] Adding:\n",
"2025-01-03 16:01:37,779 [MainThread ] [INFO ] ['a24737b9-84a2-4f72-9a98-6ee5096ac702/JZ4_posres.itp', 'a24737b9-84a2-4f72-9a98-6ee5096ac702/JZ4params.itp', 'a24737b9-84a2-4f72-9a98-6ee5096ac702/ligand.top', 'a24737b9-84a2-4f72-9a98-6ee5096ac702/posre.itp']\n",
"2025-01-03 16:01:37,779 [MainThread ] [INFO ] to: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_JZ4_complex.top.zip\n",
"2025-01-03 16:01:37,780 [MainThread ] [INFO ] Removed: ['a24737b9-84a2-4f72-9a98-6ee5096ac702/JZ4params.itp', 'a24737b9-84a2-4f72-9a98-6ee5096ac702/JZ4_posres.itp', 'a24737b9-84a2-4f72-9a98-6ee5096ac702/posre.itp', 'a24737b9-84a2-4f72-9a98-6ee5096ac702/ligand.top']\n",
"2025-01-03 16:01:37,780 [MainThread ] [INFO ] Removed: ['a24737b9-84a2-4f72-9a98-6ee5096ac702']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 16,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# AppendLigand: Append a ligand to a GROMACS topology\n",
"# Import module\n",
"from biobb_gromacs.gromacs_extra.append_ligand import append_ligand\n",
"\n",
"# Create prop dict and inputs/outputs\n",
"output_complex_top = pdbCode+'_'+ligandCode+'_complex.top.zip'\n",
"\n",
"posresifdef = \"POSRES_\"+ligandCode.upper()\n",
"prop = {\n",
" 'posres_name': posresifdef\n",
"}\n",
"\n",
"# Create and launch bb\n",
"append_ligand(input_top_zip_path=output_pdb2gmx_top_zip,\n",
" input_posres_itp_path=output_restraints_top,\n",
" input_itp_path=output_acpype_itp, \n",
" output_top_zip_path=output_complex_top,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 17,
"id": "bdd1dc3b-ee12-4ec9-9539-48d7ab186e04",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:38.423812Z",
"iopub.status.busy": "2025-01-03T07:01:38.423405Z",
"iopub.status.idle": "2025-01-03T07:01:38.471348Z",
"shell.execute_reply": "2025-01-03T07:01:38.471063Z",
"shell.execute_reply.started": "2025-01-03T07:01:38.423795Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:38,449 [MainThread ] [INFO ] Executing biobb_gromacs.gromacs.editconf Version: 4.2.0\n",
"2025-01-03 16:01:38,450 [MainThread ] [INFO ] Copy: 3HTB_JZ4_H.pdb to /home/iwatobipen/dev/sandbox/biobb_demo/ec07fcbf-074b-46c4-a72f-31da96df4451\n",
"2025-01-03 16:01:38,450 [MainThread ] [INFO ] Distance of the box to molecule: 0.80\n",
"2025-01-03 16:01:38,450 [MainThread ] [INFO ] Centering molecule in the box.\n",
"2025-01-03 16:01:38,451 [MainThread ] [INFO ] Box type: octahedron\n",
"2025-01-03 16:01:38,451 [MainThread ] [INFO ] gmx -nobackup -nocopyright editconf -f /home/iwatobipen/dev/sandbox/biobb_demo/ec07fcbf-074b-46c4-a72f-31da96df4451/3HTB_JZ4_H.pdb -o /home/iwatobipen/dev/sandbox/biobb_demo/ec07fcbf-074b-46c4-a72f-31da96df4451/3HTB_JZ4_complex_editconf.gro -bt octahedron -d 0.8 -c\n",
"\n",
"2025-01-03 16:01:38,468 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:38,468 [MainThread ] [INFO ] Note that major changes are planned in future for editconf, to improve usability and utility.\n",
"Read 2636 atoms\n",
"Volume: 1322.29 nm^3, corresponds to roughly 595000 electrons\n",
"No velocities found\n",
" system size : 4.069 4.192 5.073 (nm)\n",
" diameter : 5.849 (nm)\n",
" center : 2.241 -1.669 -0.935 (nm)\n",
" box vectors : 8.404 10.796 14.574 (nm)\n",
" box angles : 90.00 90.00 90.00 (degrees)\n",
" box volume :1322.29 (nm^3)\n",
" shift : 1.483 6.937 3.976 (nm)\n",
"new center : 3.725 5.267 3.041 (nm)\n",
"new box vectors : 7.449 7.449 7.449 (nm)\n",
"new box angles : 70.53 109.47 70.53 (degrees)\n",
"new box volume : 318.21 (nm^3)\n",
"\n",
"2025-01-03 16:01:38,468 [MainThread ] [INFO ] :-) GROMACS - gmx editconf, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx -nobackup -nocopyright editconf -f /home/iwatobipen/dev/sandbox/biobb_demo/ec07fcbf-074b-46c4-a72f-31da96df4451/3HTB_JZ4_H.pdb -o /home/iwatobipen/dev/sandbox/biobb_demo/ec07fcbf-074b-46c4-a72f-31da96df4451/3HTB_JZ4_complex_editconf.gro -bt octahedron -d 0.8 -c\n",
"\n",
"\n",
"GROMACS reminds you: \"It is disconcerting to reflect on the number of students we have flunked in chemistry for not knowing what we later found to be untrue.\" (Robert L. Weber)\n",
"\n",
"\n",
"2025-01-03 16:01:38,469 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/ec07fcbf-074b-46c4-a72f-31da96df4451']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 17,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from biobb_gromacs.gromacs.editconf import editconf\n",
"output_editconf_gro = pdbCode+'_'+ligandCode+'_complex_editconf.gro'\n",
"prop = {\n",
" 'box_type':'octahedron',\n",
" 'distance_to_molecule':0.8\n",
"}\n",
"editconf(input_gro_path=complexFile_H,\n",
" output_gro_path=output_editconf_gro,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 18,
"id": "7336443f-9db2-4136-97f5-e98ab5e3fddc",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:38.878741Z",
"iopub.status.busy": "2025-01-03T07:01:38.878556Z",
"iopub.status.idle": "2025-01-03T07:01:39.006388Z",
"shell.execute_reply": "2025-01-03T07:01:39.006024Z",
"shell.execute_reply.started": "2025-01-03T07:01:38.878726Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:38,906 [MainThread ] [INFO ] Executing biobb_gromacs.gromacs.solvate Version: 4.2.0\n",
"2025-01-03 16:01:38,908 [MainThread ] [INFO ] Copy: 3HTB_JZ4_complex_editconf.gro to /home/iwatobipen/dev/sandbox/biobb_demo/b3fc9049-6132-430b-a9e4-104e1f7d1251\n",
"2025-01-03 16:01:38,910 [MainThread ] [INFO ] Extracting: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_JZ4_complex.top.zip\n",
"2025-01-03 16:01:38,910 [MainThread ] [INFO ] to:\n",
"2025-01-03 16:01:38,910 [MainThread ] [INFO ] ['6c6063ec-abe9-4795-be75-2cc61e027ce0/JZ4_posres.itp', '6c6063ec-abe9-4795-be75-2cc61e027ce0/JZ4params.itp', '6c6063ec-abe9-4795-be75-2cc61e027ce0/ligand.top', '6c6063ec-abe9-4795-be75-2cc61e027ce0/posre.itp']\n",
"2025-01-03 16:01:38,911 [MainThread ] [INFO ] Unzipping: \n",
"2025-01-03 16:01:38,911 [MainThread ] [INFO ] 3HTB_JZ4_complex.top.zip\n",
"2025-01-03 16:01:38,911 [MainThread ] [INFO ] To: \n",
"2025-01-03 16:01:38,912 [MainThread ] [INFO ] 6c6063ec-abe9-4795-be75-2cc61e027ce0/JZ4_posres.itp\n",
"2025-01-03 16:01:38,912 [MainThread ] [INFO ] 6c6063ec-abe9-4795-be75-2cc61e027ce0/JZ4params.itp\n",
"2025-01-03 16:01:38,913 [MainThread ] [INFO ] 6c6063ec-abe9-4795-be75-2cc61e027ce0/ligand.top\n",
"2025-01-03 16:01:38,913 [MainThread ] [INFO ] 6c6063ec-abe9-4795-be75-2cc61e027ce0/posre.itp\n",
"2025-01-03 16:01:38,914 [MainThread ] [INFO ] gmx -nobackup -nocopyright solvate -cp /home/iwatobipen/dev/sandbox/biobb_demo/b3fc9049-6132-430b-a9e4-104e1f7d1251/3HTB_JZ4_complex_editconf.gro -cs spc216.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/b3fc9049-6132-430b-a9e4-104e1f7d1251/3HTB_JZ4_solvate.gro -p 6c6063ec-abe9-4795-be75-2cc61e027ce0/ligand.top\n",
"\n",
"2025-01-03 16:01:38,995 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:38,995 [MainThread ] [INFO ] \n",
"WARNING: Masses and atomic (Van der Waals) radii will be guessed\n",
" based on residue and atom names, since they could not be\n",
" definitively assigned from the information in your input\n",
" files. These guessed numbers might deviate from the mass\n",
" and radius of the atom type. Please check the output\n",
" files if necessary. Note, that this functionality may\n",
" be removed in a future GROMACS version. Please, consider\n",
" using another file format for your input.\n",
"\n",
"NOTE: From version 5.0 gmx solvate uses the Van der Waals radii\n",
"from the source below. This means the results may be different\n",
"compared to previous GROMACS versions.\n",
"\n",
"++++ PLEASE READ AND CITE THE FOLLOWING REFERENCE ++++\n",
"A. Bondi\n",
"van der Waals Volumes and Radii\n",
"J. Phys. Chem. 68 (1964) pp. 441-451\n",
"-------- -------- --- Thank You --- -------- --------\n",
"\n",
"Adding line for 9531 solvent molecules with resname (SOL) to topology file (6c6063ec-abe9-4795-be75-2cc61e027ce0/ligand.top)\n",
"\n",
"2025-01-03 16:01:38,995 [MainThread ] [INFO ] :-) GROMACS - gmx solvate, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx -nobackup -nocopyright solvate -cp /home/iwatobipen/dev/sandbox/biobb_demo/b3fc9049-6132-430b-a9e4-104e1f7d1251/3HTB_JZ4_complex_editconf.gro -cs spc216.gro -o /home/iwatobipen/dev/sandbox/biobb_demo/b3fc9049-6132-430b-a9e4-104e1f7d1251/3HTB_JZ4_solvate.gro -p 6c6063ec-abe9-4795-be75-2cc61e027ce0/ligand.top\n",
"\n",
"Reading solute configuration\n",
"Reading solvent configuration\n",
"\n",
"Initialising inter-atomic distances...\n",
"Generating solvent configuration\n",
"Will generate new solvent configuration of 5x4x4 boxes\n",
"Solvent box contains 36060 atoms in 12020 residues\n",
"Removed 5094 solvent atoms due to solvent-solvent overlap\n",
"Removed 2373 solvent atoms due to solute-solvent overlap\n",
"Sorting configuration\n",
"Found 1 molecule type:\n",
" SOL ( 3 atoms): 9531 residues\n",
"Generated solvent containing 28593 atoms in 9531 residues\n",
"Writing generated configuration to /home/iwatobipen/dev/sandbox/biobb_demo/b3fc9049-6132-430b-a9e4-104e1f7d1251/3HTB_JZ4_solvate.gro\n",
"\n",
"Output configuration contains 31229 atoms in 9695 residues\n",
"Volume : 318.205 (nm^3)\n",
"Density : 1000.12 (g/l)\n",
"Number of solvent molecules: 9531 \n",
"\n",
"Processing topology\n",
"\n",
"GROMACS reminds you: \"It is disconcerting to reflect on the number of students we have flunked in chemistry for not knowing what we later found to be untrue.\" (Robert L. Weber)\n",
"\n",
"\n",
"2025-01-03 16:01:38,997 [MainThread ] [INFO ] Compressing topology to: /home/iwatobipen/dev/sandbox/biobb_demo/b3fc9049-6132-430b-a9e4-104e1f7d1251/3HTB_JZ4_solvate_top.zip\n",
"2025-01-03 16:01:38,997 [MainThread ] [INFO ] Ignored file 6c6063ec-abe9-4795-be75-2cc61e027ce0/amber99sb-ildn.ff/forcefield.itp\n",
"2025-01-03 16:01:39,000 [MainThread ] [INFO ] Ignored file 6c6063ec-abe9-4795-be75-2cc61e027ce0/amber99sb-ildn.ff/spce.itp\n",
"2025-01-03 16:01:39,001 [MainThread ] [INFO ] Ignored file 6c6063ec-abe9-4795-be75-2cc61e027ce0/amber99sb-ildn.ff/ions.itp\n",
"2025-01-03 16:01:39,002 [MainThread ] [INFO ] Adding:\n",
"2025-01-03 16:01:39,002 [MainThread ] [INFO ] ['6c6063ec-abe9-4795-be75-2cc61e027ce0/JZ4_posres.itp', '6c6063ec-abe9-4795-be75-2cc61e027ce0/JZ4params.itp', '6c6063ec-abe9-4795-be75-2cc61e027ce0/ligand.top', '6c6063ec-abe9-4795-be75-2cc61e027ce0/posre.itp']\n",
"2025-01-03 16:01:39,003 [MainThread ] [INFO ] to: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_JZ4_solvate_top.zip\n",
"2025-01-03 16:01:39,003 [MainThread ] [INFO ] Removed: ['6c6063ec-abe9-4795-be75-2cc61e027ce0/JZ4params.itp', '6c6063ec-abe9-4795-be75-2cc61e027ce0/JZ4_posres.itp', '6c6063ec-abe9-4795-be75-2cc61e027ce0/posre.itp', '6c6063ec-abe9-4795-be75-2cc61e027ce0/ligand.top']\n",
"2025-01-03 16:01:39,004 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/b3fc9049-6132-430b-a9e4-104e1f7d1251', '6c6063ec-abe9-4795-be75-2cc61e027ce0']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 18,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from biobb_gromacs.gromacs.solvate import solvate\n",
"\n",
"output_solvate_gro = pdbCode+'_'+ligandCode+'_solvate.gro'\n",
"output_solvate_top_zip = pdbCode+'_'+ligandCode+'_solvate_top.zip'\n",
"\n",
"solvate(input_solute_gro_path=output_editconf_gro,\n",
" output_gro_path=output_solvate_gro,\n",
" input_top_zip_path=output_complex_top,\n",
" output_top_zip_path=output_solvate_top_zip)"
]
},
{
"cell_type": "code",
"execution_count": 19,
"id": "8dd01e15-dcb5-4b76-ae21-e42ad2ce74f1",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:40.433233Z",
"iopub.status.busy": "2025-01-03T07:01:40.433056Z",
"iopub.status.idle": "2025-01-03T07:01:40.480348Z",
"shell.execute_reply": "2025-01-03T07:01:40.479967Z",
"shell.execute_reply.started": "2025-01-03T07:01:40.433223Z"
}
},
"outputs": [
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "7b61cae4fa6f403482064b5158534528",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"NGLWidget()"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"#Show protein\n",
"view = nglview.show_structure_file(output_solvate_gro)\n",
"view.clear_representations()\n",
"view.add_representation(repr_type='cartoon', selection='protein', color='sstruc')\n",
"view.add_representation(repr_type='licorice', radius='.5', selection=ligandCode)\n",
"view.add_representation(repr_type='line', linewidth='1', selection='SOL', opacity='.3')\n",
"view._remote_call('setSize', target='Widget', args=['','600px'])\n",
"view.camera='orthographic'\n",
"view"
]
},
{
"cell_type": "code",
"execution_count": 20,
"id": "96327469-f14f-4e23-b413-fb91698a17ba",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:41.354824Z",
"iopub.status.busy": "2025-01-03T07:01:41.354688Z",
"iopub.status.idle": "2025-01-03T07:01:41.527410Z",
"shell.execute_reply": "2025-01-03T07:01:41.527128Z",
"shell.execute_reply.started": "2025-01-03T07:01:41.354814Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:41,384 [MainThread ] [INFO ] Executing biobb_gromacs.gromacs.grompp Version: 4.2.0\n",
"2025-01-03 16:01:41,385 [MainThread ] [INFO ] Copy: 3HTB_JZ4_solvate.gro to /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503\n",
"2025-01-03 16:01:41,386 [MainThread ] [INFO ] Extracting: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_JZ4_solvate_top.zip\n",
"2025-01-03 16:01:41,386 [MainThread ] [INFO ] to:\n",
"2025-01-03 16:01:41,386 [MainThread ] [INFO ] ['/home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/JZ4_posres.itp', '/home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/JZ4params.itp', '/home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/ligand.top', '/home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/posre.itp']\n",
"2025-01-03 16:01:41,387 [MainThread ] [INFO ] Unzipping: \n",
"2025-01-03 16:01:41,387 [MainThread ] [INFO ] 3HTB_JZ4_solvate_top.zip\n",
"2025-01-03 16:01:41,387 [MainThread ] [INFO ] To: \n",
"2025-01-03 16:01:41,387 [MainThread ] [INFO ] /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/JZ4_posres.itp\n",
"2025-01-03 16:01:41,387 [MainThread ] [INFO ] /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/JZ4params.itp\n",
"2025-01-03 16:01:41,388 [MainThread ] [INFO ] /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/ligand.top\n",
"2025-01-03 16:01:41,388 [MainThread ] [INFO ] /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/posre.itp\n",
"2025-01-03 16:01:41,388 [MainThread ] [INFO ] gmx -nobackup -nocopyright grompp -f /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/grompp.mdp -c /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/3HTB_JZ4_solvate.gro -r /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/3HTB_JZ4_solvate.gro -p /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/ligand.top -o /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/3HTB_JZ4_complex_gppion.tpr -po mdout.mdp -maxwarn 1\n",
"\n",
"2025-01-03 16:01:41,523 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:41,523 [MainThread ] [INFO ] Setting the LD random seed to -714473809\n",
"\n",
"Generated 2556 of the 2556 non-bonded parameter combinations\n",
"\n",
"Generated 2556 of the 2556 1-4 parameter combinations\n",
"\n",
"Excluding 3 bonded neighbours molecule type 'Protein_chain_A'\n",
"\n",
"Excluding 3 bonded neighbours molecule type 'JZ4params'\n",
"\n",
"Excluding 2 bonded neighbours molecule type 'SOL'\n",
"\n",
"++++ PLEASE READ AND CITE THE FOLLOWING REFERENCE ++++\n",
"J. S. Hub, B. L. de Groot, H. Grubmueller, G. Groenhof\n",
"Quantifying Artifacts in Ewald Simulations of Inhomogeneous Systems with a Net\n",
"Charge\n",
"J. Chem. Theory Comput. 10 (2014) pp. 381-393\n",
"-------- -------- --- Thank You --- -------- --------\n",
"\n",
"Analysing residue names:\n",
"There are: 163 Protein residues\n",
"There are: 1 Other residues\n",
"There are: 9531 Water residues\n",
"Analysing Protein...\n",
"Analysing residues not classified as Protein/DNA/RNA/Water and splitting into groups...\n",
"\n",
"The largest distance between excluded atoms is 0.419 nm between atom 1874 and 1881\n",
"Calculating fourier grid dimensions for X Y Z\n",
"Using a fourier grid of 64x64x64, spacing 0.116 0.116 0.116\n",
"\n",
"Estimate for the relative computational load of the PME mesh part: 0.25\n",
"\n",
"This run will generate roughly 2 Mb of data\n",
"\n",
"2025-01-03 16:01:41,524 [MainThread ] [INFO ] :-) GROMACS - gmx grompp, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx -nobackup -nocopyright grompp -f /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/grompp.mdp -c /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/3HTB_JZ4_solvate.gro -r /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/3HTB_JZ4_solvate.gro -p /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/ligand.top -o /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/3HTB_JZ4_complex_gppion.tpr -po mdout.mdp -maxwarn 1\n",
"\n",
"Ignoring obsolete mdp entry 'ns-type'\n",
"Generating 1-4 interactions: fudge = 0.5\n",
"\n",
"NOTE 1 [file ligand.top, line 24863]:\n",
" System has non-zero total charge: 6.000000\n",
" Total charge should normally be an integer. See\n",
" https://manual.gromacs.org/current/user-guide/floating-point.html\n",
" for discussion on how close it should be to an integer.\n",
"\n",
"\n",
"\n",
"\n",
"WARNING 1 [file ligand.top, line 24863]:\n",
" You are using Ewald electrostatics in a system with net charge. This can\n",
" lead to severe artifacts, such as ions moving into regions with low\n",
" dielectric, due to the uniform background charge. We suggest to\n",
" neutralize your system with counter ions, possibly in combination with a\n",
" physiological salt concentration.\n",
"\n",
"Number of degrees of freedom in T-Coupling group rest is 65091.00\n",
"The integrator does not provide a ensemble temperature, there is no system ensemble temperature\n",
"\n",
"NOTE 2 [file /home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503/grompp.mdp]:\n",
" Removing center of mass motion in the presence of position restraints\n",
" might cause artifacts. When you are using position restraints to\n",
" equilibrate a macro-molecule, the artifacts are usually negligible.\n",
"\n",
"\n",
"There were 2 NOTEs\n",
"\n",
"There was 1 WARNING\n",
"\n",
"GROMACS reminds you: \"Yeah, uh uh, Neil's Head !\" (Neil)\n",
"\n",
"\n",
"2025-01-03 16:01:41,525 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/2ccb12e3-2e43-4f59-9f01-e82b39058503', 'mdout.mdp']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 20,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# Grompp: Creating portable binary run file for ion generation\n",
"from biobb_gromacs.gromacs.grompp import grompp\n",
"\n",
"# Create prop dict and inputs/outputs\n",
"prop = {\n",
" 'mdp':{\n",
" 'nsteps':'5000'\n",
" },\n",
" 'simulation_type':'ions',\n",
" 'maxwarn': 1\n",
"}\n",
"output_gppion_tpr = pdbCode+'_'+ligandCode+'_complex_gppion.tpr'\n",
"\n",
"# Create and launch bb\n",
"grompp(input_gro_path=output_solvate_gro,\n",
" input_top_zip_path=output_solvate_top_zip, \n",
" output_tpr_path=output_gppion_tpr,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 21,
"id": "8e354d5d-6243-4f23-9616-40c18fbdbaf1",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:42.289132Z",
"iopub.status.busy": "2025-01-03T07:01:42.288991Z",
"iopub.status.idle": "2025-01-03T07:01:42.360313Z",
"shell.execute_reply": "2025-01-03T07:01:42.360037Z",
"shell.execute_reply.started": "2025-01-03T07:01:42.289123Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:42,315 [MainThread ] [INFO ] Executing biobb_gromacs.gromacs.genion Version: 4.2.0\n",
"2025-01-03 16:01:42,316 [MainThread ] [INFO ] Copy: 3HTB_JZ4_complex_gppion.tpr to /home/iwatobipen/dev/sandbox/biobb_demo/a4526ef9-1b74-46ad-94e3-86cdf99c1005\n",
"2025-01-03 16:01:42,317 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/4369b510-f3ac-4baa-a134-3ffad9fda0eb.stdin to /home/iwatobipen/dev/sandbox/biobb_demo/a4526ef9-1b74-46ad-94e3-86cdf99c1005\n",
"2025-01-03 16:01:42,318 [MainThread ] [INFO ] Extracting: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_JZ4_solvate_top.zip\n",
"2025-01-03 16:01:42,318 [MainThread ] [INFO ] to:\n",
"2025-01-03 16:01:42,318 [MainThread ] [INFO ] ['642bd761-684b-4922-9cd6-e010ab8f571f/JZ4_posres.itp', '642bd761-684b-4922-9cd6-e010ab8f571f/JZ4params.itp', '642bd761-684b-4922-9cd6-e010ab8f571f/ligand.top', '642bd761-684b-4922-9cd6-e010ab8f571f/posre.itp']\n",
"2025-01-03 16:01:42,319 [MainThread ] [INFO ] Unzipping: \n",
"2025-01-03 16:01:42,319 [MainThread ] [INFO ] 3HTB_JZ4_solvate_top.zip\n",
"2025-01-03 16:01:42,319 [MainThread ] [INFO ] To: \n",
"2025-01-03 16:01:42,319 [MainThread ] [INFO ] 642bd761-684b-4922-9cd6-e010ab8f571f/JZ4_posres.itp\n",
"2025-01-03 16:01:42,319 [MainThread ] [INFO ] 642bd761-684b-4922-9cd6-e010ab8f571f/JZ4params.itp\n",
"2025-01-03 16:01:42,319 [MainThread ] [INFO ] 642bd761-684b-4922-9cd6-e010ab8f571f/ligand.top\n",
"2025-01-03 16:01:42,319 [MainThread ] [INFO ] 642bd761-684b-4922-9cd6-e010ab8f571f/posre.itp\n",
"2025-01-03 16:01:42,320 [MainThread ] [INFO ] gmx -nobackup -nocopyright genion -s /home/iwatobipen/dev/sandbox/biobb_demo/a4526ef9-1b74-46ad-94e3-86cdf99c1005/3HTB_JZ4_complex_gppion.tpr -o /home/iwatobipen/dev/sandbox/biobb_demo/a4526ef9-1b74-46ad-94e3-86cdf99c1005/3HTB_JZ4_genion.gro -p 642bd761-684b-4922-9cd6-e010ab8f571f/ligand.top -neutral -seed 1993 < /home/iwatobipen/dev/sandbox/biobb_demo/a4526ef9-1b74-46ad-94e3-86cdf99c1005/4369b510-f3ac-4baa-a134-3ffad9fda0eb.stdin\n",
"\n",
"2025-01-03 16:01:42,350 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:42,351 [MainThread ] [INFO ] Will try to add 0 NA ions and 6 CL ions.\n",
"Select a continuous group of solvent molecules\n",
"Selected 15: 'SOL'\n",
"\n",
"Processing topology\n",
"Replacing 6 solute molecules in topology file (642bd761-684b-4922-9cd6-e010ab8f571f/ligand.top) by 0 NA and 6 CL ions.\n",
"\n",
"2025-01-03 16:01:42,351 [MainThread ] [INFO ] :-) GROMACS - gmx genion, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx -nobackup -nocopyright genion -s /home/iwatobipen/dev/sandbox/biobb_demo/a4526ef9-1b74-46ad-94e3-86cdf99c1005/3HTB_JZ4_complex_gppion.tpr -o /home/iwatobipen/dev/sandbox/biobb_demo/a4526ef9-1b74-46ad-94e3-86cdf99c1005/3HTB_JZ4_genion.gro -p 642bd761-684b-4922-9cd6-e010ab8f571f/ligand.top -neutral -seed 1993\n",
"\n",
"Reading file /home/iwatobipen/dev/sandbox/biobb_demo/a4526ef9-1b74-46ad-94e3-86cdf99c1005/3HTB_JZ4_complex_gppion.tpr, VERSION 2024.4-plumed_2.9.2 (single precision)\n",
"Reading file /home/iwatobipen/dev/sandbox/biobb_demo/a4526ef9-1b74-46ad-94e3-86cdf99c1005/3HTB_JZ4_complex_gppion.tpr, VERSION 2024.4-plumed_2.9.2 (single precision)\n",
"Group 0 ( System) has 31229 elements\n",
"Group 1 ( Protein) has 2614 elements\n",
"Group 2 ( Protein-H) has 1301 elements\n",
"Group 3 ( C-alpha) has 163 elements\n",
"Group 4 ( Backbone) has 489 elements\n",
"Group 5 ( MainChain) has 653 elements\n",
"Group 6 ( MainChain+Cb) has 805 elements\n",
"Group 7 ( MainChain+H) has 815 elements\n",
"Group 8 ( SideChain) has 1799 elements\n",
"Group 9 ( SideChain-H) has 648 elements\n",
"Group 10 ( Prot-Masses) has 2614 elements\n",
"Group 11 ( non-Protein) has 28615 elements\n",
"Group 12 ( Other) has 22 elements\n",
"Group 13 ( JZ4) has 22 elements\n",
"Group 14 ( Water) has 28593 elements\n",
"Group 15 ( SOL) has 28593 elements\n",
"Group 16 ( non-Water) has 2636 elements\n",
"Select a group: Number of (3-atomic) solvent molecules: 9531\n",
"Using random seed 1993.\n",
"Replacing solvent molecule 860 (atom 5216) with CL\n",
"Replacing solvent molecule 1675 (atom 7661) with CL\n",
"Replacing solvent molecule 4571 (atom 16349) with CL\n",
"Replacing solvent molecule 3247 (atom 12377) with CL\n",
"Replacing solvent molecule 8335 (atom 27641) with CL\n",
"Replacing solvent molecule 8692 (atom 28712) with CL\n",
"\n",
"\n",
"GROMACS reminds you: \"What if you're wrong about the great Ju Ju at the bottom of the sea?\" (Richard Dawkins)\n",
"\n",
"\n",
"2025-01-03 16:01:42,352 [MainThread ] [INFO ] Compressing topology to: /home/iwatobipen/dev/sandbox/biobb_demo/a4526ef9-1b74-46ad-94e3-86cdf99c1005/3HTB_JZ4_genion_top.zip\n",
"2025-01-03 16:01:42,352 [MainThread ] [INFO ] Ignored file 642bd761-684b-4922-9cd6-e010ab8f571f/amber99sb-ildn.ff/forcefield.itp\n",
"2025-01-03 16:01:42,355 [MainThread ] [INFO ] Ignored file 642bd761-684b-4922-9cd6-e010ab8f571f/amber99sb-ildn.ff/spce.itp\n",
"2025-01-03 16:01:42,356 [MainThread ] [INFO ] Ignored file 642bd761-684b-4922-9cd6-e010ab8f571f/amber99sb-ildn.ff/ions.itp\n",
"2025-01-03 16:01:42,357 [MainThread ] [INFO ] Adding:\n",
"2025-01-03 16:01:42,357 [MainThread ] [INFO ] ['642bd761-684b-4922-9cd6-e010ab8f571f/JZ4_posres.itp', '642bd761-684b-4922-9cd6-e010ab8f571f/JZ4params.itp', '642bd761-684b-4922-9cd6-e010ab8f571f/ligand.top', '642bd761-684b-4922-9cd6-e010ab8f571f/posre.itp']\n",
"2025-01-03 16:01:42,357 [MainThread ] [INFO ] to: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_JZ4_genion_top.zip\n",
"2025-01-03 16:01:42,357 [MainThread ] [INFO ] Removed: ['642bd761-684b-4922-9cd6-e010ab8f571f/JZ4params.itp', '642bd761-684b-4922-9cd6-e010ab8f571f/JZ4_posres.itp', '642bd761-684b-4922-9cd6-e010ab8f571f/posre.itp', '642bd761-684b-4922-9cd6-e010ab8f571f/ligand.top']\n",
"2025-01-03 16:01:42,358 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/a4526ef9-1b74-46ad-94e3-86cdf99c1005', '642bd761-684b-4922-9cd6-e010ab8f571f', '/home/iwatobipen/dev/sandbox/biobb_demo/4369b510-f3ac-4baa-a134-3ffad9fda0eb.stdin']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 21,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# Genion: Adding ions to reach a 0.05 molar concentration\n",
"from biobb_gromacs.gromacs.genion import genion\n",
"\n",
"# Create prop dict and inputs/outputs\n",
"prop={\n",
" 'neutral':True,\n",
" 'concentration':0\n",
"}\n",
"output_genion_gro = pdbCode+'_'+ligandCode+'_genion.gro'\n",
"output_genion_top_zip = pdbCode+'_'+ligandCode+'_genion_top.zip'\n",
"\n",
"# Create and launch bb\n",
"genion(input_tpr_path=output_gppion_tpr,\n",
" output_gro_path=output_genion_gro, \n",
" input_top_zip_path=output_solvate_top_zip,\n",
" output_top_zip_path=output_genion_top_zip, \n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 22,
"id": "e34d7232-1599-47e4-b006-c1a839de625c",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:43.843531Z",
"iopub.status.busy": "2025-01-03T07:01:43.843359Z",
"iopub.status.idle": "2025-01-03T07:01:43.903271Z",
"shell.execute_reply": "2025-01-03T07:01:43.902738Z",
"shell.execute_reply.started": "2025-01-03T07:01:43.843519Z"
}
},
"outputs": [
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "476933cc1ade47f183e6147f642c3d56",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"NGLWidget()"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"#Show protein\n",
"view = nglview.show_structure_file(output_genion_gro)\n",
"view.clear_representations()\n",
"view.add_representation(repr_type='cartoon', selection='protein', color='sstruc')\n",
"view.add_representation(repr_type='licorice', radius='.5', selection=ligandCode)\n",
"view.add_representation(repr_type='ball+stick', selection='NA')\n",
"view.add_representation(repr_type='ball+stick', selection='CL')\n",
"view._remote_call('setSize', target='Widget', args=['','600px'])\n",
"view.camera='orthographic'\n",
"view"
]
},
{
"cell_type": "code",
"execution_count": 23,
"id": "d999cec9-f6c8-4927-ad84-e0c5cc9c894c",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:44.705839Z",
"iopub.status.busy": "2025-01-03T07:01:44.705641Z",
"iopub.status.idle": "2025-01-03T07:01:44.875584Z",
"shell.execute_reply": "2025-01-03T07:01:44.875270Z",
"shell.execute_reply.started": "2025-01-03T07:01:44.705824Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:44,734 [MainThread ] [INFO ] Executing biobb_gromacs.gromacs.grompp Version: 4.2.0\n",
"2025-01-03 16:01:44,735 [MainThread ] [INFO ] Copy: 3HTB_JZ4_genion.gro to /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812\n",
"2025-01-03 16:01:44,736 [MainThread ] [INFO ] Extracting: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_JZ4_genion_top.zip\n",
"2025-01-03 16:01:44,736 [MainThread ] [INFO ] to:\n",
"2025-01-03 16:01:44,736 [MainThread ] [INFO ] ['/home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/JZ4_posres.itp', '/home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/JZ4params.itp', '/home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/ligand.top', '/home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/posre.itp']\n",
"2025-01-03 16:01:44,736 [MainThread ] [INFO ] Unzipping: \n",
"2025-01-03 16:01:44,736 [MainThread ] [INFO ] 3HTB_JZ4_genion_top.zip\n",
"2025-01-03 16:01:44,736 [MainThread ] [INFO ] To: \n",
"2025-01-03 16:01:44,737 [MainThread ] [INFO ] /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/JZ4_posres.itp\n",
"2025-01-03 16:01:44,737 [MainThread ] [INFO ] /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/JZ4params.itp\n",
"2025-01-03 16:01:44,737 [MainThread ] [INFO ] /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/ligand.top\n",
"2025-01-03 16:01:44,737 [MainThread ] [INFO ] /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/posre.itp\n",
"2025-01-03 16:01:44,738 [MainThread ] [INFO ] gmx -nobackup -nocopyright grompp -f /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/grompp.mdp -c /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/3HTB_JZ4_genion.gro -r /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/3HTB_JZ4_genion.gro -p /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/ligand.top -o /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/3HTB_JZ4_gppmin.tpr -po mdout.mdp -maxwarn 10\n",
"\n",
"2025-01-03 16:01:44,871 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:44,872 [MainThread ] [INFO ] Setting the LD random seed to -35817035\n",
"\n",
"Generated 2556 of the 2556 non-bonded parameter combinations\n",
"\n",
"Generated 2556 of the 2556 1-4 parameter combinations\n",
"\n",
"Excluding 3 bonded neighbours molecule type 'Protein_chain_A'\n",
"\n",
"Excluding 3 bonded neighbours molecule type 'JZ4params'\n",
"\n",
"Excluding 2 bonded neighbours molecule type 'SOL'\n",
"\n",
"Excluding 1 bonded neighbours molecule type 'CL'\n",
"Analysing residue names:\n",
"There are: 163 Protein residues\n",
"There are: 1 Other residues\n",
"There are: 9525 Water residues\n",
"There are: 6 Ion residues\n",
"Analysing Protein...\n",
"Analysing residues not classified as Protein/DNA/RNA/Water and splitting into groups...\n",
"\n",
"The largest distance between excluded atoms is 0.419 nm between atom 1874 and 1881\n",
"Calculating fourier grid dimensions for X Y Z\n",
"Using a fourier grid of 64x64x64, spacing 0.116 0.116 0.116\n",
"\n",
"Estimate for the relative computational load of the PME mesh part: 0.25\n",
"\n",
"This run will generate roughly 2 Mb of data\n",
"\n",
"2025-01-03 16:01:44,872 [MainThread ] [INFO ] :-) GROMACS - gmx grompp, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx -nobackup -nocopyright grompp -f /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/grompp.mdp -c /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/3HTB_JZ4_genion.gro -r /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/3HTB_JZ4_genion.gro -p /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/ligand.top -o /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/3HTB_JZ4_gppmin.tpr -po mdout.mdp -maxwarn 10\n",
"\n",
"Ignoring obsolete mdp entry 'ns-type'\n",
"Generating 1-4 interactions: fudge = 0.5\n",
"Number of degrees of freedom in T-Coupling group rest is 65073.00\n",
"The integrator does not provide a ensemble temperature, there is no system ensemble temperature\n",
"\n",
"NOTE 1 [file /home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812/grompp.mdp]:\n",
" Removing center of mass motion in the presence of position restraints\n",
" might cause artifacts. When you are using position restraints to\n",
" equilibrate a macro-molecule, the artifacts are usually negligible.\n",
"\n",
"\n",
"There was 1 NOTE\n",
"\n",
"GROMACS reminds you: \"The Lord of the Rings can be confusing to follow because many of the bad minions look and sound familiar; that's why Tolkien gave them each an ORCid.\" (Caroline Bartman)\n",
"\n",
"\n",
"2025-01-03 16:01:44,873 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/46dabddf-27fb-45df-b06d-468529a37812', 'mdout.mdp']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 23,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# Grompp: Creating portable binary run file for mdrun\n",
"from biobb_gromacs.gromacs.grompp import grompp\n",
"\n",
"# Create prop dict and inputs/outputs\n",
"prop = {\n",
" 'mdp':{\n",
" 'nsteps':'5000',\n",
" 'emstep': 0.01,\n",
" 'emtol':'500'\n",
" },\n",
" 'simulation_type':'minimization'\n",
"}\n",
"output_gppmin_tpr = pdbCode+'_'+ligandCode+'_gppmin.tpr'\n",
"\n",
"# Create and launch bb\n",
"grompp(input_gro_path=output_genion_gro,\n",
" input_top_zip_path=output_genion_top_zip,\n",
" output_tpr_path=output_gppmin_tpr,\n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 24,
"id": "52d191d9-caf7-4a4a-9e99-10e9d0cfc501",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:45.663259Z",
"iopub.status.busy": "2025-01-03T07:01:45.663099Z",
"iopub.status.idle": "2025-01-03T07:01:48.859156Z",
"shell.execute_reply": "2025-01-03T07:01:48.858793Z",
"shell.execute_reply.started": "2025-01-03T07:01:45.663249Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:45,689 [MainThread ] [INFO ] Executing biobb_gromacs.gromacs.mdrun Version: 4.2.0\n",
"2025-01-03 16:01:45,690 [MainThread ] [INFO ] Copy: 3HTB_JZ4_gppmin.tpr to /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de\n",
"2025-01-03 16:01:45,690 [MainThread ] [INFO ] gmx -nobackup -nocopyright mdrun -o /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de/3HTB_JZ4_min.trr -s /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de/3HTB_JZ4_gppmin.tpr -c /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de/3HTB_JZ4_min.gro -e /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de/3HTB_JZ4_min.edr -g /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de/3HTB_JZ4_min.log\n",
"\n",
"2025-01-03 16:01:48,854 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:48,854 [MainThread ] [INFO ] :-) GROMACS - gmx mdrun, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx -nobackup -nocopyright mdrun -o /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de/3HTB_JZ4_min.trr -s /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de/3HTB_JZ4_gppmin.tpr -c /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de/3HTB_JZ4_min.gro -e /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de/3HTB_JZ4_min.edr -g /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de/3HTB_JZ4_min.log\n",
"\n",
"Reading file /home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de/3HTB_JZ4_gppmin.tpr, VERSION 2024.4-plumed_2.9.2 (single precision)\n",
"1 GPU selected for this run.\n",
"Mapping of GPU IDs to the 1 GPU task in the 1 rank on this node:\n",
" PP:0\n",
"PP tasks will do (non-perturbed) short-ranged interactions on the GPU\n",
"PP task will update and constrain coordinates on the CPU\n",
"Using 1 MPI thread\n",
"Using 20 OpenMP threads \n",
"\n",
"\n",
"Steepest Descents:\n",
" Tolerance (Fmax) = 5.00000e+02\n",
" Number of steps = 5000\n",
"\n",
"writing lowest energy coordinates.\n",
"\n",
"Steepest Descents converged to Fmax < 500 in 1388 steps\n",
"Potential Energy = -5.3760388e+05\n",
"Maximum force = 4.0423395e+02 on atom 2542\n",
"Norm of force = 1.4562672e+01\n",
"\n",
"GROMACS reminds you: \"All You Need is Greed\" (Aztec Camera)\n",
"\n",
"\n",
"2025-01-03 16:01:48,856 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/acdcffdd-fe2a-4f78-89f8-c6cb9fd1b2de']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 24,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# Mdrun: Running minimization\n",
"from biobb_gromacs.gromacs.mdrun import mdrun\n",
"\n",
"# Create prop dict and inputs/outputs\n",
"output_min_trr = pdbCode+'_'+ligandCode+'_min.trr'\n",
"output_min_gro = pdbCode+'_'+ligandCode+'_min.gro'\n",
"output_min_edr = pdbCode+'_'+ligandCode+'_min.edr'\n",
"output_min_log = pdbCode+'_'+ligandCode+'_min.log'\n",
"\n",
"# Create and launch bb\n",
"mdrun(input_tpr_path=output_gppmin_tpr,\n",
" output_trr_path=output_min_trr, \n",
" output_gro_path=output_min_gro,\n",
" output_edr_path=output_min_edr, \n",
" output_log_path=output_min_log\n",
" )"
]
},
{
"cell_type": "code",
"execution_count": 25,
"id": "2b5ae6b3-050f-432d-8c55-dc684915b631",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:01:48.859658Z",
"iopub.status.busy": "2025-01-03T07:01:48.859564Z",
"iopub.status.idle": "2025-01-03T07:01:48.887564Z",
"shell.execute_reply": "2025-01-03T07:01:48.887231Z",
"shell.execute_reply.started": "2025-01-03T07:01:48.859649Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2025-01-03 16:01:48,868 [MainThread ] [INFO ] Executing biobb_analysis.gromacs.gmx_energy Version: 4.2.0\n",
"2025-01-03 16:01:48,869 [MainThread ] [INFO ] Copy: /home/iwatobipen/dev/sandbox/biobb_demo/3HTB_JZ4_min.edr to /home/iwatobipen/dev/sandbox/biobb_demo/fa7a8fb0-da6d-4d83-b7d5-9ca94d7cf488\n",
"2025-01-03 16:01:48,869 [MainThread ] [INFO ] gmx energy -f /home/iwatobipen/dev/sandbox/biobb_demo/fa7a8fb0-da6d-4d83-b7d5-9ca94d7cf488/3HTB_JZ4_min.edr -o /home/iwatobipen/dev/sandbox/biobb_demo/fa7a8fb0-da6d-4d83-b7d5-9ca94d7cf488/3HTB_JZ4_min_ene.xvg -xvg none < 5417a42d-55ac-40e2-92a8-7f332cb2c971/instructions.in\n",
"\n",
"2025-01-03 16:01:48,883 [MainThread ] [INFO ] Exit code 0\n",
"\n",
"2025-01-03 16:01:48,883 [MainThread ] [INFO ] \n",
"Statistics over 1388 steps [ 0.0000 through 1387.0000 ps ], 1 data sets\n",
"All statistics are over 1098 points (frames)\n",
"\n",
"Energy Average Err.Est. RMSD Tot-Drift\n",
"-------------------------------------------------------------------------------\n",
"Potential -520888 8800 22739.3 -57763.2 (kJ/mol)\n",
"\n",
"2025-01-03 16:01:48,883 [MainThread ] [INFO ] :-) GROMACS - gmx energy, 2024.4-plumed_2.9.2 (-:\n",
"\n",
"Executable: /usr/local/gromacs/bin/gmx\n",
"Data prefix: /usr/local/gromacs\n",
"Working dir: /home/iwatobipen/dev/sandbox/biobb_demo\n",
"Command line:\n",
" gmx energy -f /home/iwatobipen/dev/sandbox/biobb_demo/fa7a8fb0-da6d-4d83-b7d5-9ca94d7cf488/3HTB_JZ4_min.edr -o /home/iwatobipen/dev/sandbox/biobb_demo/fa7a8fb0-da6d-4d83-b7d5-9ca94d7cf488/3HTB_JZ4_min_ene.xvg -xvg none\n",
"\n",
"Opened /home/iwatobipen/dev/sandbox/biobb_demo/fa7a8fb0-da6d-4d83-b7d5-9ca94d7cf488/3HTB_JZ4_min.edr as single precision energy file\n",
"\n",
"Select the terms you want from the following list by\n",
"selecting either (part of) the name or the number or a combination.\n",
"End your selection with an empty line or a zero.\n",
"-------------------------------------------------------------------\n",
" 1 Bond 2 Angle 3 Proper-Dih. 4 Per.-Imp.-Dih.\n",
" 5 LJ-14 6 Coulomb-14 7 LJ-(SR) 8 Coulomb-(SR) \n",
" 9 Coul.-recip. 10 Position-Rest. 11 Potential 12 Pressure \n",
" 13 Vir-XX 14 Vir-XY 15 Vir-XZ 16 Vir-YX \n",
" 17 Vir-YY 18 Vir-YZ 19 Vir-ZX 20 Vir-ZY \n",
" 21 Vir-ZZ 22 Pres-XX 23 Pres-XY 24 Pres-XZ \n",
" 25 Pres-YX 26 Pres-YY 27 Pres-YZ 28 Pres-ZX \n",
" 29 Pres-ZY 30 Pres-ZZ 31 #Surf*SurfTen 32 T-rest \n",
"\n",
"Last energy frame read 1097 time 1387.000 \n",
"\n",
"GROMACS reminds you: \"All You Need is Greed\" (Aztec Camera)\n",
"\n",
"\n",
"2025-01-03 16:01:48,885 [MainThread ] [INFO ] Removed: ['/home/iwatobipen/dev/sandbox/biobb_demo/fa7a8fb0-da6d-4d83-b7d5-9ca94d7cf488', '5417a42d-55ac-40e2-92a8-7f332cb2c971']\n"
]
},
{
"data": {
"text/plain": [
"0"
]
},
"execution_count": 25,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# GMXEnergy: Getting system energy by time \n",
"from biobb_analysis.gromacs.gmx_energy import gmx_energy\n",
"\n",
"# Create prop dict and inputs/outputs\n",
"output_min_ene_xvg = pdbCode+'_'+ligandCode+'_min_ene.xvg'\n",
"prop = {\n",
" 'terms': [\"Potential\"]\n",
"}\n",
"\n",
"# Create and launch bb\n",
"gmx_energy(input_energy_path=output_min_edr, \n",
" output_xvg_path=output_min_ene_xvg, \n",
" properties=prop)"
]
},
{
"cell_type": "code",
"execution_count": 26,
"id": "3a31bf80-be5a-4df5-a957-5053014f4207",
"metadata": {
"execution": {
"iopub.execute_input": "2025-01-03T07:02:01.365832Z",
"iopub.status.busy": "2025-01-03T07:02:01.365633Z",
"iopub.status.idle": "2025-01-03T07:02:01.490254Z",
"shell.execute_reply": "2025-01-03T07:02:01.489846Z",
"shell.execute_reply.started": "2025-01-03T07:02:01.365818Z"
}
},
"outputs": [
{
"data": {
"text/html": [
" <script type=\"text/javascript\">\n",
" window.PlotlyConfig = {MathJaxConfig: 'local'};\n",
" if (window.MathJax && window.MathJax.Hub && window.MathJax.Hub.Config) {window.MathJax.Hub.Config({SVG: {font: \"STIX-Web\"}});}\n",
" if (typeof require !== 'undefined') {\n",
" require.undef(\"plotly\");\n",
" define('plotly', function(require, exports, module) {\n",
" /**\n",
"* plotly.js v2.35.2\n",
"* Copyright 2012-2024, Plotly, Inc.\n",
"* All rights reserved.\n",
"* Licensed under the MIT license\n",
"*/\n",
"/*! For license information please see plotly.min.js.LICENSE.txt */\n",
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment