Skip to content

Commit

Permalink
Merge pull request #133 from favreau/master
Browse files Browse the repository at this point in the history
Notebooks cleanup
  • Loading branch information
favreau authored Jun 20, 2022
2 parents c921a97 + 0c330af commit c38348d
Show file tree
Hide file tree
Showing 12 changed files with 30 additions and 30 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"metadata": {},
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, AnimationParams, MovieMaker, Protein, Sugars, Quaternion\n",
"from bioexplorer import BioExplorer, AnimationParams, MovieMaker, Protein, Sugar, Quaternion\n",
"uri = 'localhost:5000'\n",
"be = BioExplorer(uri)\n",
"core = be.core_api()\n",
Expand Down Expand Up @@ -106,7 +106,7 @@
" '''High-mannose'''\n",
" indices = [61, 122, 234, 603, 709, 717, 801, 1074]\n",
"\n",
" high_mannose_glycans = Sugars(\n",
" high_mannose_glycans = Sugar(\n",
" rotation=Quaternion(0.707, 0.0, 0.0, 0.707),\n",
" assembly_name=name, name=be.NAME_GLYCAN_HIGH_MANNOSE, \n",
" protein_name=name, source=high_mannose_paths[0], \n",
Expand All @@ -123,7 +123,7 @@
"\n",
" for index in [323, 325]:\n",
" o_glycan_name = name + '_' + be.NAME_GLYCAN_O_GLYCAN + '_' + str(index)\n",
" o_glycan = Sugars(\n",
" o_glycan = Sugar(\n",
" assembly_name=name, name=o_glycan_name, source=o_glycan_paths[0],\n",
" protein_name=protein_name, site_indices=[index],\n",
" representation=glycan_representation,\n",
Expand All @@ -136,7 +136,7 @@
" if open_spike:\n",
" indices = [17, 74, 149, 165, 282, 331, 343, 657, 1098, 1134, 1158, 1173, 1194]\n",
"\n",
" complex_glycans = Sugars(\n",
" complex_glycans = Sugar(\n",
" rotation=Quaternion(0.0, 0.0, 0.0, 1.0),\n",
" assembly_name=name, name=be.NAME_GLYCAN_COMPLEX, \n",
" protein_name=name, source=complex_paths[0], \n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, Protein, Surfactant, Membrane, Volume, \\\n",
" Cell, Sugars, AnimationParams, Vector2, Vector3, Quaternion, MovieMaker\n",
" Cell, Sugar, AnimationParams, Vector2, Vector3, Quaternion, MovieMaker\n",
"import glob\n",
"\n",
"url = 'localhost:5000'\n",
Expand Down Expand Up @@ -226,7 +226,7 @@
" [739, Quaternion(0.707, 0.0, 0.707, 0.0)]]\n",
" for index in indices:\n",
" o_glycan_name = name + '_' + be.NAME_GLYCAN_O_GLYCAN + '_' + str(index[0])\n",
" o_glycan = Sugars(\n",
" o_glycan = Sugar(\n",
" assembly_name=name, name=o_glycan_name, \n",
" source=o_glycan_paths[0],\n",
" protein_name=name + '_' + be.NAME_RECEPTOR, \n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"metadata": {},
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, Protein, Membrane, Cell, Sugars, \\\n",
"from bioexplorer import BioExplorer, Protein, Membrane, Cell, Sugar, \\\n",
" AnimationParams, Vector2, Vector3, Quaternion, MovieMaker\n",
"be = BioExplorer('localhost:5000')\n",
"core = be.core_api()\n",
Expand Down Expand Up @@ -151,7 +151,7 @@
" [739, Quaternion(0.707, 0.0, 0.707, 0.0)]]\n",
" for index in indices:\n",
" o_glycan_name = name + '_' + be.NAME_GLYCAN_O_GLYCAN + '_' + str(index[0])\n",
" o_glycan = Sugars(\n",
" o_glycan = Sugar(\n",
" assembly_name=name, name=o_glycan_name, \n",
" source=o_glycan_paths[0],\n",
" protein_name=name + '_' + be.NAME_RECEPTOR, \n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"metadata": {},
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, Protein, Sugars, Quaternion, MovieMaker\n",
"from bioexplorer import BioExplorer, Protein, Sugar, Quaternion, MovieMaker\n",
"import os\n",
"\n",
"be = BioExplorer('localhost:5000')\n",
Expand Down Expand Up @@ -231,7 +231,7 @@
"outputs": [],
"source": [
"glycan_name = name + '_Complex'\n",
"glycans = Sugars(\n",
"glycans = Sugar(\n",
" rotation=Quaternion(0.707, 0.0, 0.0, 0.707),\n",
" assembly_name=name, name=glycan_name, protein_name=name,\n",
" source=os.path.join(complex_folder, '36.pdb'),\n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"metadata": {},
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, Protein, Sugars, Quaternion\n",
"from bioexplorer import BioExplorer, Protein, Sugar, Quaternion\n",
"be = BioExplorer('localhost:5000')\n",
"be.reset_scene()\n",
"print(be.version())\n",
Expand Down Expand Up @@ -136,7 +136,7 @@
"outputs": [],
"source": [
"indices = [48, 66]\n",
"complex_glycans = Sugars(\n",
"complex_glycans = Sugar(\n",
" rotation=Quaternion(0.707, 0.0, 0.0, 0.707),\n",
" assembly_name=name, name=be.NAME_GLYCAN_COMPLEX, \n",
" protein_name=name, source=complex_paths[0], \n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"metadata": {},
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, Protein, Sugars, Quaternion\n",
"from bioexplorer import BioExplorer, Protein, Sugar, Quaternion\n",
"be = BioExplorer('localhost:5000')\n",
"be.reset_scene()\n",
"print(be.version())\n",
Expand Down Expand Up @@ -117,7 +117,7 @@
"outputs": [],
"source": [
"indices = [5]\n",
"high_mannose_glycans = Sugars(\n",
"high_mannose_glycans = Sugar(\n",
" rotation=Quaternion(0.707, 0.0, 0.0, 0.707),\n",
" assembly_name=name, name=be.NAME_GLYCAN_HIGH_MANNOSE, \n",
" protein_name=name, source=high_mannose_paths[0], \n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, Protein, Surfactant, Membrane, Volume, \\\n",
" Cell, Sugars, Vector2, Vector3, Quaternion, AnimationParams\n",
" Cell, Sugar, Vector2, Vector3, Quaternion, AnimationParams\n",
"import nglview\n",
"\n",
"be = BioExplorer('localhost:5000')"
Expand Down Expand Up @@ -239,7 +239,7 @@
" [739, Quaternion(0.707, 0.0, 0.707, 0.0)]]\n",
"for index in indices:\n",
" o_glycan_name = name + '_' + be.NAME_GLYCAN_O_GLYCAN + '_' + str(index[0])\n",
" o_glycan = Sugars(\n",
" o_glycan = Sugar(\n",
" assembly_name=name, name=o_glycan_name, \n",
" source=o_glycan_paths[0],\n",
" protein_name=name + '_' + be.NAME_RECEPTOR, \n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"metadata": {},
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, Protein, Sugars, Quaternion, MovieMaker\n",
"from bioexplorer import BioExplorer, Protein, Sugar, Quaternion, MovieMaker\n",
"be = BioExplorer()\n",
"core = be.core_api()\n",
"print(be.version())\n",
Expand Down Expand Up @@ -145,7 +145,7 @@
"source": [
"indices = [61, 122, 234, 603, 709, 717, 801, 1074]\n",
"\n",
"high_mannose_glycans = Sugars(\n",
"high_mannose_glycans = Sugar(\n",
" rotation=Quaternion(0.707, 0.0, 0.0, 0.707),\n",
" assembly_name=name, name=be.NAME_GLYCAN_HIGH_MANNOSE, \n",
" protein_name=name, source=high_mannose_paths[0], \n",
Expand Down Expand Up @@ -176,7 +176,7 @@
" \n",
"for index in [323, 325]:\n",
" o_glycan_name = name + '_' + be.NAME_GLYCAN_O_GLYCAN + '_' + str(index)\n",
" o_glycan = Sugars(\n",
" o_glycan = Sugar(\n",
" assembly_name=name, name=o_glycan_name, source=o_glycan_paths[0],\n",
" protein_name=protein_name, site_indices=[index],\n",
" representation=glycan_representation)\n",
Expand All @@ -201,7 +201,7 @@
"if open_spike:\n",
" indices = [17, 74, 149, 165, 282, 331, 343, 657, 1098, 1134, 1158, 1173, 1194]\n",
"\n",
"complex_glycans = Sugars(\n",
"complex_glycans = Sugar(\n",
" rotation=Quaternion(0.0, 0.0, 0.0, 1.0),\n",
" assembly_name=name, name=be.NAME_GLYCAN_COMPLEX, \n",
" protein_name=name, source=complex_paths[0], \n",
Expand Down Expand Up @@ -439,7 +439,7 @@
"\n",
"indices = [modified_aa_index]\n",
"glycan_variant_name = be.NAME_GLYCAN_COMPLEX + '_variant'\n",
"complex_glycans = Sugars(\n",
"complex_glycans = Sugar(\n",
" assembly_name=name, name=glycan_variant_name,\n",
" protein_name=name, source=complex_paths[0], \n",
" site_indices=indices,\n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"metadata": {},
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, Protein, Membrane, Cell, Sugars, \\\n",
"from bioexplorer import BioExplorer, Protein, Membrane, Cell, Sugar, \\\n",
" AnimationParams, Vector2, Vector3, Quaternion, MovieMaker\n",
"\n",
"be = BioExplorer('localhost:5000')\n",
Expand Down Expand Up @@ -208,7 +208,7 @@
" [730, Quaternion(0.0, 0.707, 0.0, 0.707)]]\n",
"for index in indices:\n",
" o_glycan_name = name + '_' + be.NAME_GLYCAN_O_GLYCAN + '_' + str(index[0])\n",
" o_glycan = Sugars(\n",
" o_glycan = Sugar(\n",
" assembly_name=name, name=o_glycan_name, \n",
" source=o_glycan_paths[0],\n",
" protein_name=name + '_' + be.NAME_RECEPTOR, \n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
},
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, Protein, Surfactant, Membrane, Cell, Sugars, \\\n",
"from bioexplorer import BioExplorer, Protein, Surfactant, Membrane, Cell, Sugar, \\\n",
" Volume, AnimationParams, Vector2, Vector3, Quaternion\n",
"import nglview\n",
"\n",
Expand Down Expand Up @@ -305,7 +305,7 @@
" [730, Quaternion(0.707, 0.0, 0.707, 0.0)]]\n",
" for index in indices:\n",
" o_glycan_name = name + '_' + be.NAME_GLYCAN_O_GLYCAN + '_' + str(index[0])\n",
" o_glycan = Sugars(\n",
" o_glycan = Sugar(\n",
" assembly_name=name, name=o_glycan_name, source=o_glycan_paths[0],\n",
" protein_name=name + '_' + be.NAME_RECEPTOR, representation=glycan_representation,\n",
" chain_ids=[2, 4], site_indices=[index[0]], rotation=index[1])\n",
Expand Down Expand Up @@ -437,7 +437,7 @@
"def add_glucose_to_surfactant_head(name):\n",
" for index in [321, 323]:\n",
" glucose_name = name + '_' + be.NAME_GLUCOSE + '_' + str(index)\n",
" glucose = Sugars(\n",
" glucose = Sugar(\n",
" assembly_name=name, name=glucose_name, source=glucose_path,\n",
" protein_name=name + '_' + be.NAME_SURFACTANT_HEAD, \n",
" representation=glycan_representation, site_indices=[index])\n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
},
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, Protein, Surfactant, Membrane, Cell, Sugars, \\\n",
"from bioexplorer import BioExplorer, Protein, Surfactant, Membrane, Cell, Sugar, \\\n",
" Volume, AnimationParams, Vector2, Vector3, Quaternion\n",
"import nglview\n",
"\n",
Expand Down Expand Up @@ -318,7 +318,7 @@
" [730, Quaternion(0.707, 0.0, 0.707, 0.0)]]\n",
" for index in indices:\n",
" o_glycan_name = name + '_' + be.NAME_GLYCAN_O_GLYCAN + '_' + str(index[0])\n",
" o_glycan = Sugars(\n",
" o_glycan = Sugar(\n",
" assembly_name=name, name=o_glycan_name, source=o_glycan_paths[0],\n",
" protein_name=name + '_' + be.NAME_RECEPTOR, representation=glycan_representation,\n",
" chain_ids=[2, 4], site_indices=[index[0]], rotation=index[1])\n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
},
"outputs": [],
"source": [
"from bioexplorer import BioExplorer, MovieMaker, Protein, ParametricMembrane, Cell, Sugars, \\\n",
"from bioexplorer import BioExplorer, MovieMaker, Protein, ParametricMembrane, Cell, Sugar, \\\n",
" Vector2, Vector3, Quaternion\n",
"\n",
"hostname = 'localhost:5000'\n",
Expand Down Expand Up @@ -201,7 +201,7 @@
" [730, Quaternion(0.707, 0.0, 0.707, 0.0)]]\n",
" for index in indices:\n",
" o_glycan_name = name + '_' + be.NAME_GLYCAN_O_GLYCAN + '_' + str(index[0])\n",
" o_glycan = Sugars(\n",
" o_glycan = Sugar(\n",
" assembly_name=name, name=o_glycan_name, source=o_glycan_paths[0],\n",
" protein_name=name + '_' + be.NAME_RECEPTOR, representation=glycan_representation,\n",
" chain_ids=[2, 4], site_indices=[index[0]], rotation=index[1])\n",
Expand Down

0 comments on commit c38348d

Please sign in to comment.