You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to use python to simulate marine environments and compute rays, arrival times etc, as I am not familiar with matlab. All works fine ( I can set and plot the environment), however when I try to compute the rays or arrival times ( arrivals = pm.compute_arrivals(env) ) I get the following message in jupyter:
[WARN] Bellhop did not generate expected output file.
As a result I can not plot the rays or arrival times, as the variable values are probably set to Nan or something. Specifically, when I try to plot arrival times I get this error:
AttributeError: 'NoneType' object has no attribute 'sort_values'
I do not know what the problem is and since there is not much information online about bellhop in python, I am stuck. Any help would be really appriciated. Thanks in advance!
Vassilis
The text was updated successfully, but these errors were encountered:
Hi, I assume the previous poster managed to find their issue and, instead of opening a new one, I figured this is quite appropriate since I also cannot generate rays (in the domain I need).
The problem is that rays with more vertical source angles bounce off the bottom and go off the domain to the left.
In the prt files, there is a message like: ray is outside the box where the ocean soundspeed is defined x = ( r, z ) = -1027.3710183331586 25.478280757985310
As far as I am concerned, those rays are lost. Is there a way to tell Bellhop to stop tracing them?
I saw something about drawing a box out of which Bellhop stops tracing rays (http://oalib.hlsresearch.com/Rays/HLS-2010-1.pdf page 10), but didn't find anything about how to define it in arlpy. It is automatically set to 101% of the distance to the furthest receiver, and indeed defining an extra sound speed column at 102% of the distance, but backwards, fixed it. Would it be possible to define that value (and by extension its depth equivalent) in arlpy? The current values are good for defaults, but it would be good to be able to set them as well. Also, I assume that is more dependent on Bellhop, but it would be great to be able to define the box in -range, or just stop tracing rays that go into "negative" range.
Thanks in advance!
arlpy supports a subset of all the options provided by BELLHOP based on common usage. If you find something that you need from BELLHOP but that isn't supported by arlpy yet, I am happy to take a PR that adds that option to arlpy.
Hello!
I'm trying to use python to simulate marine environments and compute rays, arrival times etc, as I am not familiar with matlab. All works fine ( I can set and plot the environment), however when I try to compute the rays or arrival times ( arrivals = pm.compute_arrivals(env) ) I get the following message in jupyter:
[WARN] Bellhop did not generate expected output file.
As a result I can not plot the rays or arrival times, as the variable values are probably set to Nan or something. Specifically, when I try to plot arrival times I get this error:
AttributeError Traceback (most recent call last)
Cell In[16], line 2
1 arrivals = pm.compute_arrivals(env)
----> 2 pm.plot_rays(arrivals, env=env, width=900)
File ~\AppData\Roaming\Python\Python311\site-packages\arlpy\uwapm.py:478, in plot_rays(rays, env, invert_colors, **kwargs)
461 def plot_rays(rays, env=None, invert_colors=False, **kwargs):
462 """Plots ray paths.
463
464 :param rays: ray paths
(...)
476 >>> pm.plot_rays(rays, width=1000)
477 """
--> 478 rays = rays.sort_values('bottom_bounces', ascending=False)
479 max_amp = _np.max(_np.abs(rays.bottom_bounces)) if len(rays.bottom_bounces) > 0 else 0
480 if max_amp <= 0:
AttributeError: 'NoneType' object has no attribute 'sort_values'
I do not know what the problem is and since there is not much information online about bellhop in python, I am stuck. Any help would be really appriciated. Thanks in advance!
Vassilis
The text was updated successfully, but these errors were encountered: