Skip to content

Conversation

@Jacketless
Copy link
Contributor

Not suggesting that this be merged with the master branch, but wanted to have a short-term fix branch that can be checked out to the HPC cluster so I can keep running simulations there.

However, if we want, this branch could form the baseline for our eventual solutions discussed in #47 #61 and #76

Added a simple, and wholly incorrect, try-execute catch in `field.py`to
return zero values for attempts at out-of-bounds field.data sampling.

This is not anticipated as a final solution, but rather is a temporary
fix to allow some simulation work to continue on HPC clusters.
@erikvansebille
Copy link
Member

I totally understand that you need a quick fix to the out-of-bounds error, so thanks for creating this (slightly dirty) hack, @Jacketless

While I'd be happy to temporarily add this code to master, we need a better solution in the long term of course.

The other option, if we don't want to 'spoil' master with these quick fixes, is that you temporarily fork parcels and then add it in your own forked version. @mlange05, what do you think?

@mlange05
Copy link

Ok, IMHO I would prefer a well-documented hack over maintaining a separate fork, since a hacky solution is better than no solution at all. I would like a clear in-place developer comment though that points to the relevant github issue, in case interested people stumble across this.

@erikvansebille
Copy link
Member

I agree with @mlange05. So if you can add some more comments, pointing to the relevant issues on the github page, @Jacketless, then I'll pull this into master

Added some documentation to reference the github issues this hot fix
refers to, as well as some more useful print output when out-of-bounds
errors are caught
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants