kind of a shower thought, but I think the usability for creating CustomMedium would be improved if we had some kind of method that automatically created the coordinates and DataArray bits given some geometry. For example:
s = td.Structure.from_data(
geometry=box,
eps_data=np.random.random((Nx, Ny, Nz))
)
and this would just use the geometry.bounds to create some evenly spaced coords inside and set up the CustomMedium.
kind of a shower thought, but I think the usability for creating CustomMedium would be improved if we had some kind of method that automatically created the coordinates and DataArray bits given some geometry. For example:
and this would just use the
geometry.bounds
to create some evenly spacedcoords
inside and set up theCustomMedium
.