flaport / fdtd

A 3D electromagnetic FDTD simulator written in Python with optional GPU support

Home Page:https://fdtd.readthedocs.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Float128 not supported on Windows

Julius-Py opened this issue · comments

I recently installed this on Windows and I'm using Jupyter notebook, It seems to not support the float 128, any thoughts?

AttributeError: module 'numpy' has no attribute 'float128'

Hi @Julius-Py ,

FDTD just uses numpy/pytorch dtypes. It depends on which platform you are on which dtypes are available. There is not much I can do to change this I'm afraid...

Hi @flaport,

I think what @Julius-Py meant was that having numpy.float128 as a dtype in backend.py in windows just causes the fdtd module to fail to initialize, and subsequently returning an error:
AttributeError: module 'numpy' has no attribute 'float128'

@Julius-Py, I did a quickfix by just removing any references to numpy.float128 in backend.py and it seemed to do the trick

That's indeed a fair point. I've pushed a fix and this issue will be solved in fdtd>=0.2.4