Skip to content

Commit fe9850f

Browse files
authored
Merge pull request #202 from Exabyte-io/feature/SOF-7545-1
Fix to_json when downloading to file
2 parents 3f6fb9c + 0f36db0 commit fe9850f

21 files changed

+124
-104
lines changed

other/materials_designer/specific_examples/defect_planar_grain_boundary_2d_boron_nitride.ipynb

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@
4141
},
4242
{
4343
"cell_type": "code",
44-
"outputs": [],
4544
"source": [
4645
"# Material selection\n",
4746
"MATERIAL_NAME = \"Boron_Nitride\" # Name of the material to import from Standata\n",
@@ -73,6 +72,7 @@
7372
"collapsed": false
7473
},
7574
"id": "338ee3c51155e086",
75+
"outputs": [],
7676
"execution_count": null
7777
},
7878
{
@@ -88,7 +88,6 @@
8888
},
8989
{
9090
"cell_type": "code",
91-
"outputs": [],
9291
"source": [
9392
"import sys\n",
9493
"\n",
@@ -104,6 +103,7 @@
104103
"collapsed": false
105104
},
106105
"id": "7e22d1f4da825575",
106+
"outputs": [],
107107
"execution_count": null
108108
},
109109
{
@@ -118,7 +118,6 @@
118118
},
119119
{
120120
"cell_type": "code",
121-
"outputs": [],
122121
"source": [
123122
"from mat3ra.standata.materials import Materials\n",
124123
"from mat3ra.made.material import Material\n",
@@ -129,6 +128,7 @@
129128
"collapsed": false
130129
},
131130
"id": "a1635c31132962f6",
131+
"outputs": [],
132132
"execution_count": null
133133
},
134134
{
@@ -144,7 +144,6 @@
144144
},
145145
{
146146
"cell_type": "code",
147-
"outputs": [],
148147
"source": [
149148
"from utils.visualize import visualize_materials\n",
150149
"\n",
@@ -155,6 +154,7 @@
155154
"collapsed": false
156155
},
157156
"id": "61f0870d8104cd21",
157+
"outputs": [],
158158
"execution_count": null
159159
},
160160
{
@@ -170,7 +170,6 @@
170170
},
171171
{
172172
"cell_type": "code",
173-
"outputs": [],
174173
"source": [
175174
"from mat3ra.made.tools.build.grain_boundary import (\n",
176175
" SurfaceGrainBoundaryConfiguration,\n",
@@ -200,6 +199,7 @@
200199
"collapsed": false
201200
},
202201
"id": "33a2c8a9be436745",
202+
"outputs": [],
203203
"execution_count": null
204204
},
205205
{
@@ -214,7 +214,6 @@
214214
},
215215
{
216216
"cell_type": "code",
217-
"outputs": [],
218217
"source": [
219218
"from utils.plot import plot_twisted_interface_solutions\n",
220219
"\n",
@@ -234,6 +233,7 @@
234233
"collapsed": false
235234
},
236235
"id": "d7007fe825463e5a",
236+
"outputs": [],
237237
"execution_count": null
238238
},
239239
{
@@ -249,7 +249,6 @@
249249
},
250250
{
251251
"cell_type": "code",
252-
"outputs": [],
253252
"source": [
254253
"selected_structure = grain_boundaries[0]\n",
255254
"\n",
@@ -265,6 +264,7 @@
265264
"collapsed": false
266265
},
267266
"id": "7f558a8e9d417cef",
267+
"outputs": [],
268268
"execution_count": null
269269
},
270270
{
@@ -279,16 +279,17 @@
279279
},
280280
{
281281
"cell_type": "code",
282-
"outputs": [],
283282
"source": [
284-
"from utils.jupyterlite import download_content_to_file\n",
283+
"from utils.jupyterlite import download_content_to_file, set_materials\n",
285284
"\n",
285+
"set_materials(selected_structure)\n",
286286
"download_content_to_file(selected_structure, \"grain_boundary_2d_boron_nitride.json\")"
287287
],
288288
"metadata": {
289289
"collapsed": false
290290
},
291291
"id": "20e46167358d63",
292+
"outputs": [],
292293
"execution_count": null
293294
}
294295
],

0 commit comments

Comments
 (0)