Comments (6)
Hey @flaport, sorry for the late response.
Oops I didn't realize that for the numpy slices (even though it's something I'm actually using a lot - just didn't put 2 and 2 together till now haha).
Ok, I ll keep working on the boundaries and open a PR when ready!
from fdtd.
Hi @iakovts,
Those are some great ideas!
-
I've always wanted to add some github actions to one of my repos. So far I haven't really taken the time to get to know it very well (I'm personally more comfortable with gitlab CI) so having someone do the first steps would be great! Thanks 😀
-
All code cleanup is welcome! Just keep in mind that I also want to keep the backend code accessible to scientists/researchers that don't always have a computer science background or are not always as comfortable with python as you or me. Sometimes that means having some code duplication for readability and ease of access. But feel free to make a PR for this, I'm pretty sure there is quite a bit that can be improved 😉
-
Yep. Sounds good. Alternatively, we could also just use feature branches which we merge into master. But for now I created a
dev
branch here.
from fdtd.
Hey @flaport,
- I'd be happy to keep working on Actions (including what you mentioned on #20), even though tbh it was my first time working with Actions too haha (only had gitlab-ci experience). As for the building a wheel part (+ publishing it on pypi I assume), I might need some help there since I've only done that 1-2 times before in a different environment. (P.S. I've used act for testing the Actions locally before moving to github and it seems to work great).
- Yeah, what I had in mind would not change the user's interaction with the package at all - just some clean-up / refactoring for developers. I'll try to provide an example when I have the time (probably by next week). Tbh it'd be great if more tests were available, since these changes might lead to side-effects. I might be able to start working on tests too, but some help would be greatly appreciated since I am not familiar with the project yet from a user standpoint as I haven't really started using it yet apart from some trying out some examples etc. - I suggest tracking refactoring and test changes on different issues.
- Great! I'll use that.
from fdtd.
Hey @iakovts,
- I'm currently pretty short on time, so I'll merge the PR for now and we can figure out how to auto build and publish wheels on a later time. This act tool seems cool, I'll definitely check it out!
- I know, I should add tests, but same as above... I'm lacking the time to work on them. I'll see what I can do in the next few weeks though...
from fdtd.
Hey @flaport,
So I've started working on the refactoring of boundaries, and as an example I've made some changes to periodic boundaries. These changes are purely "cosmetic", just made to avoid some repetitions of similar classes etc. I would also like to avoid setting self.__class__ = ...
there as I believe it's too implicit, but that would be probably require some major changes (plus I am still not super familiar with the whole package so it could be unavoidable?).
Also, in a completely unrelated note, is self.loc
missing a slice(None)
here ? I was probably going to start working on it too and I noticed it.
from fdtd.
thanks @iakovts, this looks good!
I think there should be a way around setting self.__class__
, which I must admit I also don't like very much. I can have a look after merging this.
For numpy arrays slice(None)
at the end of the tuple is equivalent with not adding it at all (e.g. think of x[:, :]
vs x[:]
for a 2D array). However, it's probably better to be more explicit here as well and add it for completeness.
from fdtd.
Related Issues (20)
- Can I simulate birefringent material (eg. liquid crystal) with this simulation? HOT 1
- is the pytorch backend differentiable? HOT 3
- Unit correction HOT 1
- parallel computation HOT 2
- Error using Cuda HOT 1
- Polarization of plane source HOT 2
- How should I implement pattern lighting? HOT 1
- Is fdtd suitable for antenna design? HOT 1
- How do I define a custom electromagnetic field profile as source, like the Import Source in the Lumerical FDTD?
- Hello! How to obtain the phase of electromagnetic field?
- ffmpeg not installed? HOT 15
- `RuntimeError: Expected all tensors to be on the same device, but found at least two devices, cuda:0 and cpu!` HOT 7
- Loading Spatial Distributions HOT 1
- Polarization for Linear Source
- Version on pypi doesn't have commit "don't use bd.float directly for type casting" and is erroring HOT 1
- The kernel appears to have died. It will restart automatically.
- Simulation of metals (complex refractive index) HOT 3
- development dependencies not downloading HOT 2
- fdtd.backend and fdtd.set_backend errors HOT 1
- Problem on running with fdtd.set_backend("torch") HOT 10
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fdtd.