Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: Should I set up tidal boundary per open boundary? #108

Open
SorooshMani-NOAA opened this issue Oct 23, 2023 · 3 comments
Open

Comments

@SorooshMani-NOAA
Copy link
Contributor

In the old pyschism API, I would just specify the type of tidal BC I needed, e.g. elevation and velocity, and it would automatically write it for all the open boundary conditions in the mesh files. It seems now that the new API requires that I know the number of open boundary conditions, and pass the conditions for each boundary separately.

This is really inconvenient when dealing with automation scripts. Do you have a suggested/preferred way of setting the boundary types for all the mesh open boundaries? Should I just say something like:

...
flags=[[0,0,3,3] for i in hgrid.boundaries.open.itertuples()]
...

or there's a better way?

@cuill
Copy link
Member

cuill commented Oct 23, 2023

@SorooshMani-NOAA Sorry for the inconvenience. These changes were made to expose more options to users as Joseph requested and to make it more robust. For example, the Pacific mesh has 9 open boundaries, including several rivers. You still need to specify bctypes for each boundary with the old API. In your case, the way you suggested can work. I'll think about if we can do it better.

@SorooshMani-NOAA
Copy link
Contributor Author

I see thank you. So for now I stick with the for-loop in my prior comment. That's good enough, but I just wanted to make sure there's no better way. Take my feedback mainly as a "legacy user" feedback; I'm used to doing something and I bring it up when I see a change!

@cuill
Copy link
Member

cuill commented Oct 23, 2023

@SorooshMani-NOAA No problem. And thanks for making an effort to test the changes, which is good to make pyschism more bug-free and user-friendly.

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

No branches or pull requests

2 participants