devsim 2.10.0__cp39-abi3-win_amd64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- devsim/__init__.py +17 -0
- devsim/devsim_py3.pyd +0 -0
- devsim/python_packages/Klaassen.py +336 -0
- devsim/python_packages/__init__.py +0 -0
- devsim/python_packages/fermi_physics.py +31 -0
- devsim/python_packages/model_create.py +262 -0
- devsim/python_packages/mos_physics.py +170 -0
- devsim/python_packages/pythonmesh.py +131 -0
- devsim/python_packages/ramp.py +101 -0
- devsim/python_packages/simple_dd.py +75 -0
- devsim/python_packages/simple_physics.py +463 -0
- devsim/umfpack/umfpack_lgpl.dll +0 -0
- devsim/umfpack/umfpack_loader.py +517 -0
- devsim/umfpack/umfshim.py +116 -0
- devsim-2.10.0.data/data/devsim_data/BUILD.md +94 -0
- devsim-2.10.0.data/data/devsim_data/CHANGES.md +773 -0
- devsim-2.10.0.data/data/devsim_data/CITATION.md +23 -0
- devsim-2.10.0.data/data/devsim_data/CODE_OF_CONDUCT.md +74 -0
- devsim-2.10.0.data/data/devsim_data/CONTRIBUTING.md +43 -0
- devsim-2.10.0.data/data/devsim_data/HOWTO.md +27 -0
- devsim-2.10.0.data/data/devsim_data/INSTALL.md +65 -0
- devsim-2.10.0.data/data/devsim_data/README.md +97 -0
- devsim-2.10.0.data/data/devsim_data/TEST.md +13 -0
- devsim-2.10.0.data/data/devsim_data/doc/devsim.pdf +0 -0
- devsim-2.10.0.data/data/devsim_data/doc/symdiff.pdf +0 -0
- devsim-2.10.0.data/data/devsim_data/examples/bioapp1/Ve0.jpg +0 -0
- devsim-2.10.0.data/data/devsim_data/examples/bioapp1/Ve0_3d.jpg +0 -0
- devsim-2.10.0.data/data/devsim_data/examples/bioapp1/Ve7.jpg +0 -0
- devsim-2.10.0.data/data/devsim_data/examples/bioapp1/Ve7_3d.jpg +0 -0
- devsim-2.10.0.data/data/devsim_data/examples/bioapp1/bioapp1_2d.py +85 -0
- devsim-2.10.0.data/data/devsim_data/examples/bioapp1/bioapp1_3d.py +85 -0
- devsim-2.10.0.data/data/devsim_data/examples/bioapp1/bioapp1_common.py +399 -0
- devsim-2.10.0.data/data/devsim_data/examples/bioapp1/disk_2d.geo +62 -0
- devsim-2.10.0.data/data/devsim_data/examples/bioapp1/disk_2d.msh +65606 -0
- devsim-2.10.0.data/data/devsim_data/examples/bioapp1/disk_3d.geo +183 -0
- devsim-2.10.0.data/data/devsim_data/examples/bioapp1/disk_3d.msh +25808 -0
- devsim-2.10.0.data/data/devsim_data/examples/capacitance/cap.lay +1587 -0
- devsim-2.10.0.data/data/devsim_data/examples/capacitance/cap1d.py +155 -0
- devsim-2.10.0.data/data/devsim_data/examples/capacitance/cap2d.py +200 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/3dblock.geo +48 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/diode_1d.py +94 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/diode_1d_custom.py +159 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/diode_2d.py +68 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/diode_common.py +253 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/diode_current.lay +3271 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/diode_density.lay +3271 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/diode_potential.lay +3272 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/gmsh_diode2d.msh +1477 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/gmsh_diode2d.py +55 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/gmsh_diode3d.msh +8557 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/gmsh_diode3d.py +74 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/gmsh_diode3d_equil.py +43 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/gmsh_diode3d_float128.py +85 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/laux2d.py +43 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/laux3d.py +54 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/laux_common.py +503 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/pythonmesh3d.py +61 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/ssac_diode.py +57 -0
- devsim-2.10.0.data/data/devsim_data/examples/diode/tran_diode.py +63 -0
- devsim-2.10.0.data/data/devsim_data/examples/mobility/gmsh_mos2d.geo +160 -0
- devsim-2.10.0.data/data/devsim_data/examples/mobility/gmsh_mos2d.msh +8599 -0
- devsim-2.10.0.data/data/devsim_data/examples/mobility/gmsh_mos2d.py +96 -0
- devsim-2.10.0.data/data/devsim_data/examples/mobility/gmsh_mos2d_create.py +174 -0
- devsim-2.10.0.data/data/devsim_data/examples/mobility/gmsh_mos2d_kla.py +162 -0
- devsim-2.10.0.data/data/devsim_data/examples/mobility/logElectrons.lay +1327 -0
- devsim-2.10.0.data/data/devsim_data/examples/mobility/pythonmesh2d.py +100 -0
- devsim-2.10.0.data/data/devsim_data/examples/mobility/test.lay +3385 -0
- devsim-2.10.0.data/data/devsim_data/examples/mobility/times.txt +34 -0
- devsim-2.10.0.data/data/devsim_data/examples/plotting/visualization.ipynb +160 -0
- devsim-2.10.0.data/data/devsim_data/examples/symdiff/arrhenius.py +24 -0
- devsim-2.10.0.data/data/devsim_data/examples/symdiff/deftest.py +48 -0
- devsim-2.10.0.data/data/devsim_data/examples/symdiff/modellist1.py +9 -0
- devsim-2.10.0.data/data/devsim_data/examples/symdiff/models1.py +41 -0
- devsim-2.10.0.data/data/devsim_data/examples/symdiff/ordered.py +9 -0
- devsim-2.10.0.data/data/devsim_data/examples/symdiff/parsetest.py +107 -0
- devsim-2.10.0.data/data/devsim_data/examples/symdiff/remove1.py +8 -0
- devsim-2.10.0.data/data/devsim_data/examples/symdiff/subexpression1.py +10 -0
- devsim-2.10.0.data/data/devsim_data/examples/symdiff/table.py +7 -0
- devsim-2.10.0.data/data/devsim_data/examples/symdiff/undefined1.py +10 -0
- devsim-2.10.0.data/data/devsim_data/examples/symdiff/utf8.py +10 -0
- devsim-2.10.0.data/data/devsim_data/examples/vectorpotential/twowire.geo +34 -0
- devsim-2.10.0.data/data/devsim_data/examples/vectorpotential/twowire.lay +1469 -0
- devsim-2.10.0.data/data/devsim_data/examples/vectorpotential/twowire.msh +13596 -0
- devsim-2.10.0.data/data/devsim_data/examples/vectorpotential/twowire.py +177 -0
- devsim-2.10.0.data/data/devsim_data/setup.cfg +23 -0
- devsim-2.10.0.data/data/devsim_data/setup.py +58 -0
- devsim-2.10.0.data/data/devsim_data/testing/3dtetmesh.msh +281 -0
- devsim-2.10.0.data/data/devsim_data/testing/CMakeLists.txt +175 -0
- devsim-2.10.0.data/data/devsim_data/testing/Fermi1.py +59 -0
- devsim-2.10.0.data/data/devsim_data/testing/Fermi1_float128.py +18 -0
- devsim-2.10.0.data/data/devsim_data/testing/GaussFermi.py +38 -0
- devsim-2.10.0.data/data/devsim_data/testing/GaussFermi_float128.py +18 -0
- devsim-2.10.0.data/data/devsim_data/testing/cap2.py +439 -0
- devsim-2.10.0.data/data/devsim_data/testing/cap_mesh.py +33 -0
- devsim-2.10.0.data/data/devsim_data/testing/circ1.py +79 -0
- devsim-2.10.0.data/data/devsim_data/testing/circ2.py +79 -0
- devsim-2.10.0.data/data/devsim_data/testing/circ3.py +18 -0
- devsim-2.10.0.data/data/devsim_data/testing/circ4.py +105 -0
- devsim-2.10.0.data/data/devsim_data/testing/dio2_element_2d.py +136 -0
- devsim-2.10.0.data/data/devsim_data/testing/dio2_element_physics.py +302 -0
- devsim-2.10.0.data/data/devsim_data/testing/equation1.py +68 -0
- devsim-2.10.0.data/data/devsim_data/testing/erf1.py +52 -0
- devsim-2.10.0.data/data/devsim_data/testing/erf2.py +34 -0
- devsim-2.10.0.data/data/devsim_data/testing/fpetest1.py +21 -0
- devsim-2.10.0.data/data/devsim_data/testing/fpetest2.py +25 -0
- devsim-2.10.0.data/data/devsim_data/testing/gmsh_mos3d.geo +272 -0
- devsim-2.10.0.data/data/devsim_data/testing/info.py +11 -0
- devsim-2.10.0.data/data/devsim_data/testing/kahan.py +24 -0
- devsim-2.10.0.data/data/devsim_data/testing/kahan_float128.py +18 -0
- devsim-2.10.0.data/data/devsim_data/testing/laux1.py +232 -0
- devsim-2.10.0.data/data/devsim_data/testing/mctest.mc +30 -0
- devsim-2.10.0.data/data/devsim_data/testing/mctest_user.mc +33 -0
- devsim-2.10.0.data/data/devsim_data/testing/mesh1.msh +52 -0
- devsim-2.10.0.data/data/devsim_data/testing/mesh1.py +121 -0
- devsim-2.10.0.data/data/devsim_data/testing/mesh2.msh +70 -0
- devsim-2.10.0.data/data/devsim_data/testing/mesh2.py +210 -0
- devsim-2.10.0.data/data/devsim_data/testing/mesh2d.py +105 -0
- devsim-2.10.0.data/data/devsim_data/testing/mesh3.py +8 -0
- devsim-2.10.0.data/data/devsim_data/testing/mesh4.py +8 -0
- devsim-2.10.0.data/data/devsim_data/testing/mos_2d.py +111 -0
- devsim-2.10.0.data/data/devsim_data/testing/mos_2d_create.py +207 -0
- devsim-2.10.0.data/data/devsim_data/testing/mos_2d_restart.py +69 -0
- devsim-2.10.0.data/data/devsim_data/testing/mos_2d_restart2.py +24 -0
- devsim-2.10.0.data/data/devsim_data/testing/noise_res.py +51 -0
- devsim-2.10.0.data/data/devsim_data/testing/noise_res_2d.py +101 -0
- devsim-2.10.0.data/data/devsim_data/testing/ptest1.py +53 -0
- devsim-2.10.0.data/data/devsim_data/testing/ptest2.py +110 -0
- devsim-2.10.0.data/data/devsim_data/testing/pythonmesh1d.py +202 -0
- devsim-2.10.0.data/data/devsim_data/testing/res1.py +65 -0
- devsim-2.10.0.data/data/devsim_data/testing/res2.py +65 -0
- devsim-2.10.0.data/data/devsim_data/testing/res3.py +59 -0
- devsim-2.10.0.data/data/devsim_data/testing/rundifftest.py +62 -0
- devsim-2.10.0.data/data/devsim_data/testing/ssac_cap.py +145 -0
- devsim-2.10.0.data/data/devsim_data/testing/ssac_cap_2d_edge.py +199 -0
- devsim-2.10.0.data/data/devsim_data/testing/ssac_cap_2d_element.py +214 -0
- devsim-2.10.0.data/data/devsim_data/testing/ssac_cap_3d_edge.py +148 -0
- devsim-2.10.0.data/data/devsim_data/testing/ssac_cap_3d_element.py +167 -0
- devsim-2.10.0.data/data/devsim_data/testing/ssac_circ.py +18 -0
- devsim-2.10.0.data/data/devsim_data/testing/ssac_res.py +30 -0
- devsim-2.10.0.data/data/devsim_data/testing/symdiff1.py +54 -0
- devsim-2.10.0.data/data/devsim_data/testing/test_common.py +435 -0
- devsim-2.10.0.data/data/devsim_data/testing/testfunc.py +65 -0
- devsim-2.10.0.data/data/devsim_data/testing/testfunc_extended.py +8 -0
- devsim-2.10.0.data/data/devsim_data/testing/transient_circ.py +67 -0
- devsim-2.10.0.data/data/devsim_data/testing/transient_circ2.py +67 -0
- devsim-2.10.0.data/data/devsim_data/testing/transient_circ3.py +125 -0
- devsim-2.10.0.data/data/devsim_data/testing/transient_rc.py +157 -0
- devsim-2.10.0.data/data/devsim_data/testing/trimesh1.msh +47 -0
- devsim-2.10.0.data/data/devsim_data/testing/trimesh1.py +114 -0
- devsim-2.10.0.data/data/devsim_data/testing/trimesh2.py +114 -0
- devsim-2.10.0.data/data/devsim_data/testing/utf8_2.py +126 -0
- devsim-2.10.0.dist-info/METADATA +121 -0
- devsim-2.10.0.dist-info/RECORD +157 -0
- devsim-2.10.0.dist-info/WHEEL +5 -0
- devsim-2.10.0.dist-info/licenses/LICENSE +202 -0
- devsim-2.10.0.dist-info/licenses/NOTICE +241 -0
- devsim-2.10.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
# Copyright 2013 DEVSIM LLC
|
|
2
|
+
#
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
5
|
+
from devsim import (
|
|
6
|
+
add_gmsh_contact,
|
|
7
|
+
add_gmsh_interface,
|
|
8
|
+
add_gmsh_region,
|
|
9
|
+
contact_equation,
|
|
10
|
+
contact_node_model,
|
|
11
|
+
create_device,
|
|
12
|
+
create_gmsh_mesh,
|
|
13
|
+
edge_from_node_model,
|
|
14
|
+
edge_model,
|
|
15
|
+
equation,
|
|
16
|
+
finalize_mesh,
|
|
17
|
+
get_element_model_values,
|
|
18
|
+
get_node_model_values,
|
|
19
|
+
interface_equation,
|
|
20
|
+
interface_model,
|
|
21
|
+
node_model,
|
|
22
|
+
node_solution,
|
|
23
|
+
set_parameter,
|
|
24
|
+
solve,
|
|
25
|
+
vector_gradient,
|
|
26
|
+
write_devices,
|
|
27
|
+
)
|
|
28
|
+
|
|
29
|
+
device = "twowire"
|
|
30
|
+
|
|
31
|
+
create_gmsh_mesh(file="twowire.msh", mesh="twowire")
|
|
32
|
+
add_gmsh_region(mesh="twowire", gmsh_name="air", region="air", material="air")
|
|
33
|
+
add_gmsh_region(mesh="twowire", gmsh_name="left", region="left", material="iron")
|
|
34
|
+
add_gmsh_region(mesh="twowire", gmsh_name="right", region="right", material="iron")
|
|
35
|
+
add_gmsh_contact(
|
|
36
|
+
mesh="twowire", gmsh_name="bottom", region="air", material="metal", name="bottom"
|
|
37
|
+
)
|
|
38
|
+
add_gmsh_interface(
|
|
39
|
+
mesh="twowire",
|
|
40
|
+
gmsh_name="air_left_interface",
|
|
41
|
+
region0="air",
|
|
42
|
+
region1="left",
|
|
43
|
+
name="air_left",
|
|
44
|
+
)
|
|
45
|
+
add_gmsh_interface(
|
|
46
|
+
mesh="twowire",
|
|
47
|
+
gmsh_name="air_right_interface",
|
|
48
|
+
region0="air",
|
|
49
|
+
region1="right",
|
|
50
|
+
name="air_right",
|
|
51
|
+
)
|
|
52
|
+
finalize_mesh(mesh="twowire")
|
|
53
|
+
create_device(mesh="twowire", device=device)
|
|
54
|
+
|
|
55
|
+
set_parameter(device=device, region="air", name="mu", value=1)
|
|
56
|
+
set_parameter(device=device, region="left", name="mu", value=1)
|
|
57
|
+
set_parameter(device=device, region="right", name="mu", value=1)
|
|
58
|
+
|
|
59
|
+
set_parameter(device=device, region="air", name="jz", value=0)
|
|
60
|
+
set_parameter(device=device, region="left", name="jz", value=1)
|
|
61
|
+
set_parameter(device=device, region="right", name="jz", value=-1)
|
|
62
|
+
|
|
63
|
+
for region in ("air", "left", "right"):
|
|
64
|
+
node_solution(device=device, region=region, name="Az")
|
|
65
|
+
edge_from_node_model(device=device, region=region, node_model="Az")
|
|
66
|
+
|
|
67
|
+
edge_model(
|
|
68
|
+
device=device,
|
|
69
|
+
region=region,
|
|
70
|
+
name="delAz",
|
|
71
|
+
equation="(Az@n1 - Az@n0) * EdgeInverseLength",
|
|
72
|
+
)
|
|
73
|
+
|
|
74
|
+
edge_model(
|
|
75
|
+
device=device, region=region, name="delAz:Az@n1", equation="EdgeInverseLength"
|
|
76
|
+
)
|
|
77
|
+
|
|
78
|
+
edge_model(
|
|
79
|
+
device=device, region=region, name="delAz:Az@n0", equation="-EdgeInverseLength"
|
|
80
|
+
)
|
|
81
|
+
|
|
82
|
+
node_model(device=device, region=region, name="Jz", equation="mu * jz")
|
|
83
|
+
|
|
84
|
+
equation(
|
|
85
|
+
device=device,
|
|
86
|
+
region=region,
|
|
87
|
+
name="Az_Equation",
|
|
88
|
+
variable_name="Az",
|
|
89
|
+
edge_model="delAz",
|
|
90
|
+
node_model="Jz",
|
|
91
|
+
)
|
|
92
|
+
|
|
93
|
+
vector_gradient(device=device, region=region, node_model="Az", calc_type="default")
|
|
94
|
+
|
|
95
|
+
node_model(device=device, region=region, name="Bx", equation="Az_grady")
|
|
96
|
+
node_model(device=device, region=region, name="By", equation="-Az_gradx")
|
|
97
|
+
|
|
98
|
+
#### interfaces
|
|
99
|
+
for interface in ("air_left", "air_right"):
|
|
100
|
+
interface_model(
|
|
101
|
+
device=device,
|
|
102
|
+
interface=interface,
|
|
103
|
+
name="continuousAz",
|
|
104
|
+
equation="Az@r0 - Az@r1",
|
|
105
|
+
)
|
|
106
|
+
interface_model(
|
|
107
|
+
device=device, interface=interface, name="continuousAz:Az@r0", equation="1.0"
|
|
108
|
+
)
|
|
109
|
+
interface_model(
|
|
110
|
+
device=device, interface=interface, name="continuousAz:Az@r1", equation="-1.0"
|
|
111
|
+
)
|
|
112
|
+
|
|
113
|
+
interface_equation(
|
|
114
|
+
device=device,
|
|
115
|
+
interface=interface,
|
|
116
|
+
name="Az_Equation",
|
|
117
|
+
interface_model="continuousAz",
|
|
118
|
+
type="continuous",
|
|
119
|
+
)
|
|
120
|
+
|
|
121
|
+
|
|
122
|
+
#### contact
|
|
123
|
+
contact_node_model(device=device, contact="bottom", name="Az_zero", equation="Az - 0")
|
|
124
|
+
contact_node_model(device=device, contact="bottom", name="Az_zero:Az", equation="1.0")
|
|
125
|
+
contact_equation(
|
|
126
|
+
device=device, contact="bottom", name="Az_Equation", node_model="Az_zero"
|
|
127
|
+
)
|
|
128
|
+
|
|
129
|
+
# write_devices(file="debug.msh")
|
|
130
|
+
|
|
131
|
+
solve(relative_error=1e-10, absolute_error=1, type="dc")
|
|
132
|
+
|
|
133
|
+
write_devices(file="gmsh_{0}_out.msh".format(device))
|
|
134
|
+
write_devices(file="gmsh_{0}_out.dat".format(device), type="tecplot")
|
|
135
|
+
|
|
136
|
+
print(
|
|
137
|
+
"ElementNodeVolume {0:e}".format(
|
|
138
|
+
sum(
|
|
139
|
+
get_element_model_values(
|
|
140
|
+
device=device, region="air", name="ElementNodeVolume"
|
|
141
|
+
)
|
|
142
|
+
)
|
|
143
|
+
)
|
|
144
|
+
)
|
|
145
|
+
print(
|
|
146
|
+
"NodeVolume {0:e}".format(
|
|
147
|
+
sum(get_node_model_values(device=device, region="air", name="NodeVolume"))
|
|
148
|
+
)
|
|
149
|
+
)
|
|
150
|
+
print(
|
|
151
|
+
"ElementNodeVolume {0:e}".format(
|
|
152
|
+
sum(
|
|
153
|
+
get_element_model_values(
|
|
154
|
+
device=device, region="left", name="ElementNodeVolume"
|
|
155
|
+
)
|
|
156
|
+
)
|
|
157
|
+
)
|
|
158
|
+
)
|
|
159
|
+
print(
|
|
160
|
+
"NodeVolume {0:e}".format(
|
|
161
|
+
sum(get_node_model_values(device=device, region="left", name="NodeVolume"))
|
|
162
|
+
)
|
|
163
|
+
)
|
|
164
|
+
print(
|
|
165
|
+
"ElementNodeVolume {0:e}".format(
|
|
166
|
+
sum(
|
|
167
|
+
get_element_model_values(
|
|
168
|
+
device=device, region="right", name="ElementNodeVolume"
|
|
169
|
+
)
|
|
170
|
+
)
|
|
171
|
+
)
|
|
172
|
+
)
|
|
173
|
+
print(
|
|
174
|
+
"NodeVolume {0:e}".format(
|
|
175
|
+
sum(get_node_model_values(device=device, region="right", name="NodeVolume"))
|
|
176
|
+
)
|
|
177
|
+
)
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
[bdist_wheel]
|
|
2
|
+
py-limited-api = cp39
|
|
3
|
+
#plat-name=
|
|
4
|
+
[metadata]
|
|
5
|
+
version = 2.10.0
|
|
6
|
+
classifiers =
|
|
7
|
+
Development Status :: 5 - Production/Stable
|
|
8
|
+
Intended Audience :: Science/Research
|
|
9
|
+
License :: OSI Approved :: Apache Software License
|
|
10
|
+
Programming Language :: Python :: 3
|
|
11
|
+
Topic :: Scientific/Engineering :: Electronic Design Automation (EDA)
|
|
12
|
+
name = devsim
|
|
13
|
+
url = https://devsim.org
|
|
14
|
+
author = Juan Sanchez and others
|
|
15
|
+
author_email = info@devsim.com
|
|
16
|
+
description = DEVSIM: TCAD Device Simulator
|
|
17
|
+
license = Apache License, Version 2.0
|
|
18
|
+
project_urls =
|
|
19
|
+
Bug Tracker = https://github.com/devsim/devsim/issues
|
|
20
|
+
Documentation = https://devsim.net
|
|
21
|
+
Source Code = https://github.com/devsim/devsim
|
|
22
|
+
Online Forum = https://forum.devsim.org
|
|
23
|
+
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
from setuptools import setup, Distribution
|
|
2
|
+
from glob import glob
|
|
3
|
+
from itertools import chain
|
|
4
|
+
import os
|
|
5
|
+
import re
|
|
6
|
+
|
|
7
|
+
#https://stackoverflow.com/questions/35112511/pip-setup-py-bdist-wheel-no-longer-builds-forced-non-pure-wheels/36886459#36886459
|
|
8
|
+
#https://stackoverflow.com/questions/24071491/how-can-i-make-a-python-wheel-from-an-existing-native-library/24793171#24793171
|
|
9
|
+
#https://github.com/google/or-tools/issues/616
|
|
10
|
+
class BinaryDistribution(Distribution):
|
|
11
|
+
"""Distribution which always forces a binary package with platform name"""
|
|
12
|
+
def has_ext_modules(foo):
|
|
13
|
+
return True
|
|
14
|
+
def is_pure(self):
|
|
15
|
+
return False
|
|
16
|
+
|
|
17
|
+
#https://stackoverflow.com/questions/27829754/include-entire-directory-in-python-setup-py-data-files/65432634#65432634
|
|
18
|
+
def generate_data_files():
|
|
19
|
+
data_files = []
|
|
20
|
+
data_dirs = ('doc', 'testing', 'examples')
|
|
21
|
+
for path, dirs, files in chain.from_iterable(os.walk(data_dir) for data_dir in data_dirs):
|
|
22
|
+
install_dir = os.path.join('devsim_data', path)
|
|
23
|
+
list_entry = (install_dir, [os.path.join(path, f) for f in files])
|
|
24
|
+
data_files.append(list_entry)
|
|
25
|
+
return data_files
|
|
26
|
+
|
|
27
|
+
data_files = [('devsim_data', glob('*.*'))]
|
|
28
|
+
data_files.extend(generate_data_files())
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
def fix_readme(text):
|
|
32
|
+
regex = re.compile('\[([^]]+)\]+\((?!http[s]:\/\/)([^)]+)\)')
|
|
33
|
+
base_url = os.environ.get('README_BASE_URL')
|
|
34
|
+
if base_url:
|
|
35
|
+
if base_url[-1] != '/':
|
|
36
|
+
base_url += '/'
|
|
37
|
+
print("Fixing up base url for long description {0}".format(base_url))
|
|
38
|
+
text = regex.sub(lambda m, urlbase=base_url : r'[{0}]({1})'.format(m.group(1), urlbase + m.group(2)), text)
|
|
39
|
+
return text
|
|
40
|
+
|
|
41
|
+
with open('README.md', 'r') as ifile:
|
|
42
|
+
text = ifile.read()
|
|
43
|
+
text = fix_readme(text)
|
|
44
|
+
|
|
45
|
+
setup(
|
|
46
|
+
packages=['devsim', 'devsim.python_packages', 'devsim.umfpack'],
|
|
47
|
+
package_dir = {
|
|
48
|
+
'' : 'lib',
|
|
49
|
+
},
|
|
50
|
+
package_data={
|
|
51
|
+
'devsim' : ['./*.so', './*.dll', './*.dylib', './*.pyd',],
|
|
52
|
+
'devsim.umfpack' : ['./*.so', './*.dll', './*.dylib', './*.pyd',],
|
|
53
|
+
},
|
|
54
|
+
distclass=BinaryDistribution,
|
|
55
|
+
data_files = data_files,
|
|
56
|
+
long_description = text,
|
|
57
|
+
long_description_content_type="text/markdown",
|
|
58
|
+
)
|
|
@@ -0,0 +1,281 @@
|
|
|
1
|
+
begin_device "test"
|
|
2
|
+
begin_coordinates
|
|
3
|
+
0.000000000000000e+00 0.000000000000000e+00 0.000000000000000e+00
|
|
4
|
+
6.000000000000000e-02 0.000000000000000e+00 0.000000000000000e+00
|
|
5
|
+
6.000000000000000e-02 6.000000000000000e-02 0.000000000000000e+00
|
|
6
|
+
0.000000000000000e+00 6.000000000000000e-02 0.000000000000000e+00
|
|
7
|
+
0.000000000000000e+00 0.000000000000000e+00 6.000000000000000e-02
|
|
8
|
+
6.000000000000000e-02 0.000000000000000e+00 6.000000000000000e-02
|
|
9
|
+
6.000000000000000e-02 6.000000000000000e-02 6.000000000000000e-02
|
|
10
|
+
0.000000000000000e+00 6.000000000000000e-02 6.000000000000000e-02
|
|
11
|
+
3.000000000000000e-02 0.000000000000000e+00 0.000000000000000e+00
|
|
12
|
+
6.000000000000000e-02 3.000000000000000e-02 0.000000000000000e+00
|
|
13
|
+
3.000000000000000e-02 6.000000000000000e-02 0.000000000000000e+00
|
|
14
|
+
0.000000000000000e+00 3.000000000000000e-02 0.000000000000000e+00
|
|
15
|
+
3.000000000000000e-02 0.000000000000000e+00 6.000000000000000e-02
|
|
16
|
+
6.000000000000000e-02 3.000000000000000e-02 6.000000000000000e-02
|
|
17
|
+
3.000000000000000e-02 6.000000000000000e-02 6.000000000000000e-02
|
|
18
|
+
0.000000000000000e+00 3.000000000000000e-02 6.000000000000000e-02
|
|
19
|
+
6.000000000000000e-02 0.000000000000000e+00 3.000000000000000e-02
|
|
20
|
+
0.000000000000000e+00 0.000000000000000e+00 3.000000000000000e-02
|
|
21
|
+
6.000000000000000e-02 6.000000000000000e-02 3.000000000000000e-02
|
|
22
|
+
0.000000000000000e+00 6.000000000000000e-02 3.000000000000000e-02
|
|
23
|
+
3.000000000000000e-02 3.000000000000000e-02 0.000000000000000e+00
|
|
24
|
+
0.000000000000000e+00 3.000000000000000e-02 3.000000000000000e-02
|
|
25
|
+
3.000000000000000e-02 6.000000000000000e-02 3.000000000000000e-02
|
|
26
|
+
6.000000000000000e-02 3.000000000000000e-02 3.000000000000000e-02
|
|
27
|
+
3.000000000000000e-02 3.000000000000000e-02 6.000000000000000e-02
|
|
28
|
+
3.000000000000000e-02 0.000000000000000e+00 3.000000000000000e-02
|
|
29
|
+
0.000000000000000e+00 1.500000000000000e-02 4.500000000000000e-02
|
|
30
|
+
1.500000000000000e-02 1.500000000000000e-02 0.000000000000000e+00
|
|
31
|
+
4.500000000000000e-02 1.500000000000000e-02 0.000000000000000e+00
|
|
32
|
+
3.000000000000000e-02 3.000000000000000e-02 3.000000000000000e-02
|
|
33
|
+
6.000000000000000e-02 1.500000000000000e-02 4.500000000000000e-02
|
|
34
|
+
4.500000000000000e-02 6.000000000000000e-02 4.500000000000000e-02
|
|
35
|
+
4.500000000000000e-02 6.000000000000000e-02 1.500000000000000e-02
|
|
36
|
+
0.000000000000000e+00 4.500000000000000e-02 4.500000000000000e-02
|
|
37
|
+
0.000000000000000e+00 4.500000000000000e-02 1.500000000000000e-02
|
|
38
|
+
end_coordinates
|
|
39
|
+
|
|
40
|
+
begin_region "bulk" "silicon"
|
|
41
|
+
begin_nodes
|
|
42
|
+
0
|
|
43
|
+
1
|
|
44
|
+
2
|
|
45
|
+
3
|
|
46
|
+
4
|
|
47
|
+
5
|
|
48
|
+
6
|
|
49
|
+
7
|
|
50
|
+
8
|
|
51
|
+
9
|
|
52
|
+
10
|
|
53
|
+
11
|
|
54
|
+
12
|
|
55
|
+
13
|
|
56
|
+
14
|
|
57
|
+
15
|
|
58
|
+
16
|
|
59
|
+
17
|
|
60
|
+
18
|
|
61
|
+
19
|
|
62
|
+
20
|
|
63
|
+
21
|
|
64
|
+
22
|
|
65
|
+
23
|
|
66
|
+
24
|
|
67
|
+
25
|
|
68
|
+
26
|
|
69
|
+
27
|
|
70
|
+
28
|
|
71
|
+
29
|
|
72
|
+
30
|
|
73
|
+
31
|
|
74
|
+
32
|
|
75
|
+
33
|
|
76
|
+
34
|
|
77
|
+
end_nodes
|
|
78
|
+
|
|
79
|
+
begin_tetrahedra
|
|
80
|
+
0 8 25 27
|
|
81
|
+
0 11 21 27
|
|
82
|
+
0 17 21 27
|
|
83
|
+
0 17 25 27
|
|
84
|
+
1 8 25 28
|
|
85
|
+
1 9 23 28
|
|
86
|
+
1 16 23 28
|
|
87
|
+
1 16 25 28
|
|
88
|
+
2 9 20 32
|
|
89
|
+
2 9 23 32
|
|
90
|
+
2 10 20 32
|
|
91
|
+
2 18 23 32
|
|
92
|
+
3 10 20 34
|
|
93
|
+
3 10 22 34
|
|
94
|
+
3 11 20 34
|
|
95
|
+
3 19 22 34
|
|
96
|
+
4 12 24 26
|
|
97
|
+
4 12 25 26
|
|
98
|
+
4 15 24 26
|
|
99
|
+
4 17 25 26
|
|
100
|
+
5 12 24 30
|
|
101
|
+
5 12 25 30
|
|
102
|
+
5 13 24 30
|
|
103
|
+
5 16 25 30
|
|
104
|
+
6 13 23 31
|
|
105
|
+
6 13 24 31
|
|
106
|
+
6 14 24 31
|
|
107
|
+
6 18 23 31
|
|
108
|
+
7 14 22 33
|
|
109
|
+
7 14 24 33
|
|
110
|
+
7 15 24 33
|
|
111
|
+
7 19 22 33
|
|
112
|
+
8 20 27 29
|
|
113
|
+
8 20 28 29
|
|
114
|
+
8 25 27 29
|
|
115
|
+
8 25 28 29
|
|
116
|
+
9 20 28 29
|
|
117
|
+
9 20 29 32
|
|
118
|
+
9 23 28 29
|
|
119
|
+
9 23 29 32
|
|
120
|
+
10 20 29 32
|
|
121
|
+
10 20 29 34
|
|
122
|
+
10 22 29 32
|
|
123
|
+
10 22 29 34
|
|
124
|
+
11 20 27 29
|
|
125
|
+
11 20 29 34
|
|
126
|
+
11 21 27 29
|
|
127
|
+
11 21 29 34
|
|
128
|
+
12 24 26 29
|
|
129
|
+
12 24 29 30
|
|
130
|
+
12 25 26 29
|
|
131
|
+
12 25 29 30
|
|
132
|
+
13 23 29 30
|
|
133
|
+
13 23 29 31
|
|
134
|
+
13 24 29 30
|
|
135
|
+
13 24 29 31
|
|
136
|
+
14 22 29 31
|
|
137
|
+
14 22 29 33
|
|
138
|
+
14 24 29 31
|
|
139
|
+
14 24 29 33
|
|
140
|
+
15 21 26 29
|
|
141
|
+
15 21 29 33
|
|
142
|
+
15 24 26 29
|
|
143
|
+
15 24 29 33
|
|
144
|
+
16 23 28 29
|
|
145
|
+
16 23 29 30
|
|
146
|
+
16 25 28 29
|
|
147
|
+
16 25 29 30
|
|
148
|
+
17 21 26 29
|
|
149
|
+
17 21 27 29
|
|
150
|
+
17 25 26 29
|
|
151
|
+
17 25 27 29
|
|
152
|
+
18 22 29 31
|
|
153
|
+
18 22 29 32
|
|
154
|
+
18 23 29 31
|
|
155
|
+
18 23 29 32
|
|
156
|
+
19 21 29 33
|
|
157
|
+
19 21 29 34
|
|
158
|
+
19 22 29 33
|
|
159
|
+
19 22 29 34
|
|
160
|
+
end_tetrahedra
|
|
161
|
+
|
|
162
|
+
begin_node_model "AtContactNode"
|
|
163
|
+
BUILTIN
|
|
164
|
+
end_node_model
|
|
165
|
+
|
|
166
|
+
begin_node_model "ContactSurfaceArea"
|
|
167
|
+
DATAPARENT "SurfaceArea"
|
|
168
|
+
end_node_model
|
|
169
|
+
|
|
170
|
+
begin_node_model "NSurfaceNormal_x"
|
|
171
|
+
DATAPARENT "SurfaceArea"
|
|
172
|
+
end_node_model
|
|
173
|
+
|
|
174
|
+
begin_node_model "NSurfaceNormal_y"
|
|
175
|
+
DATAPARENT "SurfaceArea"
|
|
176
|
+
end_node_model
|
|
177
|
+
|
|
178
|
+
begin_node_model "NSurfaceNormal_z"
|
|
179
|
+
DATAPARENT "SurfaceArea"
|
|
180
|
+
end_node_model
|
|
181
|
+
|
|
182
|
+
begin_node_model "NodeVolume"
|
|
183
|
+
BUILTIN
|
|
184
|
+
end_node_model
|
|
185
|
+
|
|
186
|
+
begin_node_model "SurfaceArea"
|
|
187
|
+
BUILTIN
|
|
188
|
+
end_node_model
|
|
189
|
+
|
|
190
|
+
begin_node_model "coordinate_index"
|
|
191
|
+
DATAPARENT "x"
|
|
192
|
+
end_node_model
|
|
193
|
+
|
|
194
|
+
begin_node_model "node_index"
|
|
195
|
+
DATAPARENT "x"
|
|
196
|
+
end_node_model
|
|
197
|
+
|
|
198
|
+
begin_node_model "x"
|
|
199
|
+
BUILTIN
|
|
200
|
+
end_node_model
|
|
201
|
+
|
|
202
|
+
begin_node_model "y"
|
|
203
|
+
DATAPARENT "x"
|
|
204
|
+
end_node_model
|
|
205
|
+
|
|
206
|
+
begin_node_model "z"
|
|
207
|
+
DATAPARENT "x"
|
|
208
|
+
end_node_model
|
|
209
|
+
|
|
210
|
+
begin_edge_model "EdgeCouple"
|
|
211
|
+
BUILTIN
|
|
212
|
+
end_edge_model
|
|
213
|
+
|
|
214
|
+
begin_edge_model "EdgeInverseLength"
|
|
215
|
+
BUILTIN
|
|
216
|
+
end_edge_model
|
|
217
|
+
|
|
218
|
+
begin_edge_model "EdgeLength"
|
|
219
|
+
BUILTIN
|
|
220
|
+
end_edge_model
|
|
221
|
+
|
|
222
|
+
begin_edge_model "edge_index"
|
|
223
|
+
BUILTIN
|
|
224
|
+
end_edge_model
|
|
225
|
+
|
|
226
|
+
begin_edge_model "unitx"
|
|
227
|
+
BUILTIN
|
|
228
|
+
end_edge_model
|
|
229
|
+
|
|
230
|
+
begin_edge_model "unity"
|
|
231
|
+
DATAPARENT "unitx"
|
|
232
|
+
end_edge_model
|
|
233
|
+
|
|
234
|
+
begin_edge_model "unitz"
|
|
235
|
+
DATAPARENT "unitx"
|
|
236
|
+
end_edge_model
|
|
237
|
+
|
|
238
|
+
begin_tetrahedron_edge_model "ElementEdgeCouple"
|
|
239
|
+
BUILTIN
|
|
240
|
+
end_tetrahedron_edge_model
|
|
241
|
+
|
|
242
|
+
begin_tetrahedron_edge_model "ElementNodeVolume"
|
|
243
|
+
BUILTIN
|
|
244
|
+
end_tetrahedron_edge_model
|
|
245
|
+
|
|
246
|
+
end_region
|
|
247
|
+
|
|
248
|
+
begin_contact "bot" "bulk" "metal"
|
|
249
|
+
begin_triangles
|
|
250
|
+
0 8 25
|
|
251
|
+
0 17 25
|
|
252
|
+
1 8 25
|
|
253
|
+
1 16 25
|
|
254
|
+
4 12 25
|
|
255
|
+
4 17 25
|
|
256
|
+
5 12 25
|
|
257
|
+
5 16 25
|
|
258
|
+
end_triangles
|
|
259
|
+
|
|
260
|
+
end_contact
|
|
261
|
+
|
|
262
|
+
begin_contact "top" "bulk" "metal"
|
|
263
|
+
begin_triangles
|
|
264
|
+
2 10 32
|
|
265
|
+
2 18 32
|
|
266
|
+
3 10 22
|
|
267
|
+
3 19 22
|
|
268
|
+
6 14 31
|
|
269
|
+
6 18 31
|
|
270
|
+
7 14 22
|
|
271
|
+
7 19 22
|
|
272
|
+
10 22 32
|
|
273
|
+
14 22 31
|
|
274
|
+
18 22 31
|
|
275
|
+
18 22 32
|
|
276
|
+
end_triangles
|
|
277
|
+
|
|
278
|
+
end_contact
|
|
279
|
+
|
|
280
|
+
end_device
|
|
281
|
+
|