Andrei tomut commited on
Commit
9b962b2
1 Parent(s): 5cbf533

new output

Browse files
.idea/.gitignore ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ # Default ignored files
2
+ /shelf/
3
+ /workspace.xml
4
+ # Editor-based HTTP Client requests
5
+ /httpRequests/
6
+ # Datasource local storage ignored files
7
+ /dataSources/
8
+ /dataSources.local.xml
.idea/inspectionProfiles/Project_Default.xml ADDED
@@ -0,0 +1,62 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <component name="InspectionProjectProfileManager">
2
+ <profile version="1.0">
3
+ <option name="myName" value="Project Default" />
4
+ <inspection_tool class="PyCompatibilityInspection" enabled="true" level="WARNING" enabled_by_default="true">
5
+ <option name="ourVersions">
6
+ <value>
7
+ <list size="2">
8
+ <item index="0" class="java.lang.String" itemvalue="3.9" />
9
+ <item index="1" class="java.lang.String" itemvalue="3.11" />
10
+ </list>
11
+ </value>
12
+ </option>
13
+ </inspection_tool>
14
+ <inspection_tool class="PyPackageRequirementsInspection" enabled="true" level="WARNING" enabled_by_default="true">
15
+ <option name="ignoredPackages">
16
+ <value>
17
+ <list size="25">
18
+ <item index="0" class="java.lang.String" itemvalue="numpy" />
19
+ <item index="1" class="java.lang.String" itemvalue="pandas" />
20
+ <item index="2" class="java.lang.String" itemvalue="symengine" />
21
+ <item index="3" class="java.lang.String" itemvalue="gpyopt" />
22
+ <item index="4" class="java.lang.String" itemvalue="matplotlib" />
23
+ <item index="5" class="java.lang.String" itemvalue="pennylane" />
24
+ <item index="6" class="java.lang.String" itemvalue="torch" />
25
+ <item index="7" class="java.lang.String" itemvalue="ase" />
26
+ <item index="8" class="java.lang.String" itemvalue="wget" />
27
+ <item index="9" class="java.lang.String" itemvalue="kahypar" />
28
+ <item index="10" class="java.lang.String" itemvalue="certifi" />
29
+ <item index="11" class="java.lang.String" itemvalue="tensorly-torch" />
30
+ <item index="12" class="java.lang.String" itemvalue="scipy" />
31
+ <item index="13" class="java.lang.String" itemvalue="setuptools" />
32
+ <item index="14" class="java.lang.String" itemvalue="tensorly" />
33
+ <item index="15" class="java.lang.String" itemvalue="evaluate" />
34
+ <item index="16" class="java.lang.String" itemvalue="transformers" />
35
+ <item index="17" class="java.lang.String" itemvalue="fastapi" />
36
+ <item index="18" class="java.lang.String" itemvalue="gradio" />
37
+ <item index="19" class="java.lang.String" itemvalue="uvicorn" />
38
+ <item index="20" class="java.lang.String" itemvalue="Requests" />
39
+ <item index="21" class="java.lang.String" itemvalue="datasets" />
40
+ <item index="22" class="java.lang.String" itemvalue="torchvision" />
41
+ <item index="23" class="java.lang.String" itemvalue="memory_profiler" />
42
+ <item index="24" class="java.lang.String" itemvalue="mendeleev" />
43
+ </list>
44
+ </value>
45
+ </option>
46
+ </inspection_tool>
47
+ <inspection_tool class="PyPep8Inspection" enabled="true" level="WEAK WARNING" enabled_by_default="true">
48
+ <option name="ignoredErrors">
49
+ <list>
50
+ <option value="E701" />
51
+ </list>
52
+ </option>
53
+ </inspection_tool>
54
+ <inspection_tool class="PyUnresolvedReferencesInspection" enabled="true" level="WARNING" enabled_by_default="true">
55
+ <option name="ignoredIdentifiers">
56
+ <list>
57
+ <option value="six.xrange" />
58
+ </list>
59
+ </option>
60
+ </inspection_tool>
61
+ </profile>
62
+ </component>
.idea/inspectionProfiles/profiles_settings.xml ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ <component name="InspectionProjectProfileManager">
2
+ <settings>
3
+ <option name="USE_PROJECT_PROFILE" value="false" />
4
+ <version value="1.0" />
5
+ </settings>
6
+ </component>
.idea/latmatcher.iml ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <module type="PYTHON_MODULE" version="4">
3
+ <component name="NewModuleRootManager">
4
+ <content url="file://$MODULE_DIR$" />
5
+ <orderEntry type="inheritedJdk" />
6
+ <orderEntry type="sourceFolder" forTests="false" />
7
+ </component>
8
+ <component name="PyDocumentationSettings">
9
+ <option name="format" value="PLAIN" />
10
+ <option name="myDocStringFormat" value="Plain" />
11
+ </component>
12
+ </module>
.idea/misc.xml ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="ProjectRootManager" version="2" project-jdk-name="Python 3.11 (latmatcher)" project-jdk-type="Python SDK" />
4
+ </project>
.idea/modules.xml ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="ProjectModuleManager">
4
+ <modules>
5
+ <module fileurl="file://$PROJECT_DIR$/.idea/latmatcher.iml" filepath="$PROJECT_DIR$/.idea/latmatcher.iml" />
6
+ </modules>
7
+ </component>
8
+ </project>
.idea/vcs.xml ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="VcsDirectoryMappings">
4
+ <mapping directory="" vcs="Git" />
5
+ </component>
6
+ </project>
app.py CHANGED
@@ -22,6 +22,7 @@ with gr.Blocks() as latmatcher:
22
 
23
  max_angle = gr.Slider(0, 180, label=" max Angle:", step=1)
24
  max_strain = gr.Slider(0, 1, label=" max Strain:", step=0.05)
 
25
 
26
  msc_button = gr.Button("Compute minimum super cel")
27
 
@@ -31,10 +32,12 @@ with gr.Blocks() as latmatcher:
31
 
32
  plot_overlap = gr.Plot()
33
 
 
 
34
  msc_button.click(compute_supercell_a,
35
- inputs=[file_material_a, file_material_b, file_source_a, file_source_b, max_angle,
36
  max_strain],
37
- outputs=[file_material_ab, file_angle, file_strain, plot_overlap])
38
 
39
  with gr.TabItem(label="data"):
40
  with gr.Row():
 
22
 
23
  max_angle = gr.Slider(0, 180, label=" max Angle:", step=1)
24
  max_strain = gr.Slider(0, 1, label=" max Strain:", step=0.05)
25
+ inter_distance = gr.Slider(-0.05, 10, label=" Inter-layer distance:",info="If set to -0.05 is computed automatically.", step=0.05)
26
 
27
  msc_button = gr.Button("Compute minimum super cel")
28
 
 
32
 
33
  plot_overlap = gr.Plot()
34
 
35
+ file_txt = gr.Text(label="Result:", info=" You can use the text below to create a 3D plot in Speck \n(high-quality atomistic system rendering).")
36
+
37
  msc_button.click(compute_supercell_a,
38
+ inputs=[file_material_a, file_material_b, inter_distance, max_angle,
39
  max_strain],
40
+ outputs=[file_material_ab, file_angle, file_strain, plot_overlap, file_txt])
41
 
42
  with gr.TabItem(label="data"):
43
  with gr.Row():
interface_connection/latmatcher_interface.py CHANGED
@@ -32,7 +32,7 @@ def get_atomic_number(element_symbol):
32
  return element.number
33
 
34
 
35
- def compute_supercell_a(file_material_a, file_material_b, file_source_a, file_source_b, max_angle, max_strain):
36
 
37
 
38
  #
@@ -105,7 +105,7 @@ def compute_supercell_a(file_material_a, file_material_b, file_source_a, file_so
105
 
106
 
107
  plot=plot_supercel(super_xyz, min_supercel)
108
- return file12, str(rez[0]), str((rez[1], rez[2])),plot
109
 
110
  def compute_supercell_b():
111
  pass
 
32
  return element.number
33
 
34
 
35
+ def compute_supercell_a(file_material_a, file_material_b,inter_distance , max_angle, max_strain):
36
 
37
 
38
  #
 
105
 
106
 
107
  plot=plot_supercel(super_xyz, min_supercel)
108
+ return file12, str(rez[0]), str((rez[1], rez[2])),plot, xyz_content
109
 
110
  def compute_supercell_b():
111
  pass