def plot(d, sphere=False):
    
    #phi = np.linspace(-np.pi, +np.pi, 50)
    #theta = np.linspace(0.0, np.pi, 50)
    phi = np.linspace(0.0, +2.0*np.pi, 50)
    theta = np.linspace(0.0, np.pi, 50)
    THETA, PHI = np.meshgrid(theta, phi)
    
    # Directivity strength. Real-valued. Can be positive and negative.
    dr = d.using_spherical(THETA, PHI)
    
    if sphere:
        x, y, z = spherical_to_cartesian(1.0, THETA, PHI)
        
    else:
        x, y, z = spherical_to_cartesian( np.abs(dr), THETA, PHI )
    #R, THETA, PHI = cartesian_to_spherical(x, y, z)
    
    fig = plt.figure()
    ax = fig.add_subplot(111, projection='3d')
    #p = ax.plot_surface(x, y, z, cmap=plt.cm.jet, rstride=1, cstride=1, linewidth=0)


    norm = Normalize()
    norm.autoscale(dr)
    colors = cm.jet(norm(dr))
    m = cm.ScalarMappable(cmap=cm.jet, norm=norm)
    m.set_array(dr)
    p = ax.plot_surface(x, y, z, facecolors=colors, rstride=1, cstride=1, linewidth=0)
    plt.colorbar(m, ax=ax)
    
    ax.set_xlabel('$x$')
    ax.set_ylabel('$y$')
    ax.set_zlabel('$z$')
    return fig
Prints tabular data of storage info.
dataset/ETHPy150Open python-acoustics/python-acoustics/acoustics/directivity.py/plot--crossover with--dataset/ETHPy150Open openlmi/openlmi-scripts/commands/system/lmi/scripts/system/__init__.py/get_storageinfo