MCPcopy Create free account
hub / github.com/NanoComp/meep / create_h5data

Method create_h5data

python/tests/test_source.py:164–173  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

162
163class TestAmpFileFunc(unittest.TestCase):
164 def create_h5data(self):
165 N = 100
166 M = 200
167
168 self.amp_data = np.zeros((N, M, 1), dtype=np.complex128)
169
170 for i in range(N):
171 for j in range(M):
172 v = mp.Vector3((i / N) * 0.3 - 0.15, (j / M) * 0.2 - 0.1)
173 self.amp_data[i, j] = amp_fun(v)
174
175 def init_and_run(self, test_type):
176 cell = mp.Vector3(1, 1)

Callers 1

test_amp_file_funcMethod · 0.95

Calls 1

amp_funFunction · 0.85

Tested by

no test coverage detected