Skip to content

Commit

Permalink
Some tests added
Browse files Browse the repository at this point in the history
  • Loading branch information
dprada committed Dec 21, 2024
1 parent 8ab823d commit 8642b10
Show file tree
Hide file tree
Showing 7 changed files with 375 additions and 87 deletions.
116 changes: 33 additions & 83 deletions docs/contents/user/tools/structure/align_principal_axes.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "acabf3aa42d247ada3e3978689397dd7",
"model_id": "54b3043c3363436e8c477185c720171e",
"version_major": 2,
"version_minor": 0
},
Expand Down Expand Up @@ -76,37 +76,37 @@
"text/html": [
"<style type=\"text/css\">\n",
"</style>\n",
"<table id=\"T_ef55f\">\n",
"<table id=\"T_ae249\">\n",
" <thead>\n",
" <tr>\n",
" <th id=\"T_ef55f_level0_col0\" class=\"col_heading level0 col0\" >form</th>\n",
" <th id=\"T_ef55f_level0_col1\" class=\"col_heading level0 col1\" >n_atoms</th>\n",
" <th id=\"T_ef55f_level0_col2\" class=\"col_heading level0 col2\" >n_groups</th>\n",
" <th id=\"T_ef55f_level0_col3\" class=\"col_heading level0 col3\" >n_components</th>\n",
" <th id=\"T_ef55f_level0_col4\" class=\"col_heading level0 col4\" >n_chains</th>\n",
" <th id=\"T_ef55f_level0_col5\" class=\"col_heading level0 col5\" >n_molecules</th>\n",
" <th id=\"T_ef55f_level0_col6\" class=\"col_heading level0 col6\" >n_entities</th>\n",
" <th id=\"T_ef55f_level0_col7\" class=\"col_heading level0 col7\" >n_lipids</th>\n",
" <th id=\"T_ef55f_level0_col8\" class=\"col_heading level0 col8\" >n_structures</th>\n",
" <th id=\"T_ae249_level0_col0\" class=\"col_heading level0 col0\" >form</th>\n",
" <th id=\"T_ae249_level0_col1\" class=\"col_heading level0 col1\" >n_atoms</th>\n",
" <th id=\"T_ae249_level0_col2\" class=\"col_heading level0 col2\" >n_groups</th>\n",
" <th id=\"T_ae249_level0_col3\" class=\"col_heading level0 col3\" >n_components</th>\n",
" <th id=\"T_ae249_level0_col4\" class=\"col_heading level0 col4\" >n_chains</th>\n",
" <th id=\"T_ae249_level0_col5\" class=\"col_heading level0 col5\" >n_molecules</th>\n",
" <th id=\"T_ae249_level0_col6\" class=\"col_heading level0 col6\" >n_entities</th>\n",
" <th id=\"T_ae249_level0_col7\" class=\"col_heading level0 col7\" >n_lipids</th>\n",
" <th id=\"T_ae249_level0_col8\" class=\"col_heading level0 col8\" >n_structures</th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <td id=\"T_ef55f_row0_col0\" class=\"data row0 col0\" >molsysmt.MolSys</td>\n",
" <td id=\"T_ef55f_row0_col1\" class=\"data row0 col1\" >134</td>\n",
" <td id=\"T_ef55f_row0_col2\" class=\"data row0 col2\" >1</td>\n",
" <td id=\"T_ef55f_row0_col3\" class=\"data row0 col3\" >1</td>\n",
" <td id=\"T_ef55f_row0_col4\" class=\"data row0 col4\" >1</td>\n",
" <td id=\"T_ef55f_row0_col5\" class=\"data row0 col5\" >1</td>\n",
" <td id=\"T_ef55f_row0_col6\" class=\"data row0 col6\" >1</td>\n",
" <td id=\"T_ef55f_row0_col7\" class=\"data row0 col7\" >1</td>\n",
" <td id=\"T_ef55f_row0_col8\" class=\"data row0 col8\" >1</td>\n",
" <td id=\"T_ae249_row0_col0\" class=\"data row0 col0\" >molsysmt.MolSys</td>\n",
" <td id=\"T_ae249_row0_col1\" class=\"data row0 col1\" >134</td>\n",
" <td id=\"T_ae249_row0_col2\" class=\"data row0 col2\" >1</td>\n",
" <td id=\"T_ae249_row0_col3\" class=\"data row0 col3\" >1</td>\n",
" <td id=\"T_ae249_row0_col4\" class=\"data row0 col4\" >1</td>\n",
" <td id=\"T_ae249_row0_col5\" class=\"data row0 col5\" >1</td>\n",
" <td id=\"T_ae249_row0_col6\" class=\"data row0 col6\" >1</td>\n",
" <td id=\"T_ae249_row0_col7\" class=\"data row0 col7\" >1</td>\n",
" <td id=\"T_ae249_row0_col8\" class=\"data row0 col8\" >1</td>\n",
" </tr>\n",
" </tbody>\n",
"</table>\n"
],
"text/plain": [
"<pandas.io.formats.style.Styler at 0x7f9c2583b2b0>"
"<pandas.io.formats.style.Styler at 0x7bc414a348d0>"
]
},
"execution_count": 5,
Expand All @@ -130,53 +130,28 @@
},
{
"cell_type": "code",
"execution_count": 7,
"execution_count": null,
"id": "922d611e-686b-46f3-a603-bed5a9adffb4",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"[ 0.09213962 -0.02624376 -0.9954002 ] 13.378581090770417\n",
"[0.56239734 0.82631277 0.03027277] 73.67866342245162\n",
"[-0.82171742 0.56259975 -0.09089556] 78.32952437971095\n"
]
}
],
"outputs": [],
"source": [
"for ii in range(3):\n",
" print(axes[0,ii], momenta[0,ii])"
]
},
{
"cell_type": "code",
"execution_count": 8,
"execution_count": null,
"id": "095cb193-a067-4940-8a4d-2c0ca5d34d80",
"metadata": {},
"outputs": [
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "877c7f96fcaa43188a75af4eefe83d19",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"NGLWidget()"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"outputs": [],
"source": [
"msm.view(molsys)"
]
},
{
"cell_type": "code",
"execution_count": 9,
"execution_count": null,
"id": "b46c0c26-d4be-41a5-a9fb-c9b97dd5bad2",
"metadata": {},
"outputs": [],
Expand All @@ -186,7 +161,7 @@
},
{
"cell_type": "code",
"execution_count": 10,
"execution_count": null,
"id": "5d29c2f5-b9ab-494e-bf26-a71de19c00c2",
"metadata": {},
"outputs": [],
Expand All @@ -196,54 +171,29 @@
},
{
"cell_type": "code",
"execution_count": 11,
"execution_count": null,
"id": "2f4e8bdb-7f79-4c72-883b-536f7ba02ee0",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"[1.00000000e+00 2.87221485e-16 8.58936055e-17] 13.37858109077042\n",
"[-2.87221485e-16 1.00000000e+00 -3.60822483e-15] 73.67866342245169\n",
"[-8.58936055e-17 3.60822483e-15 1.00000000e+00] 78.32952437971095\n"
]
}
],
"outputs": [],
"source": [
"for ii in range(3):\n",
" print(axes[0,ii], momenta[0,ii])"
]
},
{
"cell_type": "code",
"execution_count": 12,
"execution_count": null,
"id": "40ec81fa-54be-4eee-8073-d7f07af8beaf",
"metadata": {},
"outputs": [
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "0fdae2ea503a4798ba16c3d433d71084",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"NGLWidget()"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"outputs": [],
"source": [
"msm.view(molsys_2)"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "39800e8d-836c-4ee6-b6c4-c05c9d139149",
"id": "485d758d-833b-425f-ad77-552d37ad421e",
"metadata": {},
"outputs": [],
"source": []
Expand All @@ -265,7 +215,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.10.14"
"version": "3.11.10"
}
},
"nbformat": 4,
Expand Down
Loading

0 comments on commit 8642b10

Please sign in to comment.