-
Notifications
You must be signed in to change notification settings - Fork 13
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
failing test on --python-only installation #19
Comments
There are also a couple of runtime-errors, seemingly division by zero or invalid argument calls |
Thank you for the update.
Those assertion errors are ok — I need to update the tests. I fixed a bug in the way TAMOC computed the tracer concentrations, and the current values are all right. The values in the test files need to be updated. Glad you could fix the other errors. If you could share how you addressed the depreciated warnings, I could update those in the code.
Thank you,
Scott
…-----------
Scott A. Socolofsky, Professor,
J. Walter “Deak” Porter ’22 and James W. “Bud” Porter ’51 Chair,
Zachry Department of Civil and Environmental Engineering
Department of Oceanography
Department of Ocean Engineering
Texas A&M University
(979) 845-4517
-----------
On Nov 10, 2022, at 2:38 AM, MichaelPotthoff ***@***.******@***.***>> wrote:
This Message Is From an External Sender
This message came from outside your organization.
Hi
I finally managed to get tamoc installed on a windows machine. I can not use miniconda, thus I followed the manual installation procedure and installed the latest development version 2.4.0 (hint: avoid spaces in the path!) - I could not get it to work with my default IBM Fortran compiler, thus I choose to install the --python-only version. When i run the test I get a couple of assertion errors (and some deprecated warnings, that I could resolve):
NumPy: 1.23.4
SciPy : 1.9.3
Matplotlib: 3.6.2
netCDF4 : 1.6.1
xarray : 2022.10.0
C:\temp>pytest -v --pyargs tamoc
================================================= test session starts =================================================
platform win32 -- Python 3.10.7, pytest-7.2.0, pluggy-1.0.0 -- C:\Python\Python310\python.exe
cachedir: .pytest_cache
rootdir: C:\temp
plugins: anyio-3.6.2
=============================================== short test summary info ===============================================
FAILED test/test_blowout.py::test_simulate - AssertionError:
FAILED test/test_bpm.py::test_plume_objs - AssertionError:
FAILED test/test_bpm.py::test_simulate - AssertionError:
FAILED test/test_bpm.py::test_files - AssertionError:
FAILED test/test_sbm.py::test_ic - PermissionError: [Errno 13] Permission denied: b'C:\tamoc-master\tamoc\test\output\test_BM54.nc'
FAILED test/test_spm.py::test_plume_objs - PermissionError: [Errno 13] Permission denied: b'C:\tamoc-master\tamoc\test\output\test_BM54.nc'
=============================== 6 failed, 69 passed, 286 warnings in 100.92s (0:01:40) ================================
for i in range(len(q0)):
assert_approx_equal(spill.bpm.q[0,i], q0[i], significant=6)
E AssertionError:
E Items are not equal to 6 significant digits:
E ACTUAL: 0.0012566370614359175
E DESIRED: 1.29037789
c:\tamoc-master\tamoc\test\test_blowout.py:471: AssertionError
assert_array_almost_equal(q_local.cte, np.array([4.36126913]), decimal=6)
E AssertionError:
E Arrays are not almost equal to 6 decimals
E
E Mismatched elements: 1 / 1 (100%)
E Max absolute difference: 4.35702798
E Max relative difference: 0.99902754
E x: array([0.004241])
E y: array([4.361269])
c:\tamoc-master\tamoc\test\test_bpm.py:501: AssertionError
for i in range(len(ans)):
assert_approx_equal(bpm.q[0,i], ans[i], significant=6)
E AssertionError:
E Items are not equal to 6 significant digits:
E ACTUAL: 0.004241150082346221
E DESIRED: 4.36126914
c:\tamoc-master\tamoc\test\test_bpm.py:270: AssertionError
and some access permission error regarding netCDF:
c:\tamoc-master\tamoc\test\test_sbm.py:254:
________________________________
c:\tamoc-master\tamoc\test\test_sbm.py:99: in get_profile
nc = make_ctd_file()
c:\tamoc-master\tamoc\test\test_sbm.py:76: in make_ctd_file
test_ambient.test_from_ctd()
c:\tamoc-master\tamoc\test\test_ambient.py:411: in test_from_ctd
nc = check_nc_db(nc_file, summary, source, sea_name, p_lat,
c:\tamoc-master\tamoc\test\test_ambient.py💯 in check_nc_db
nc = ambient.create_nc_db(nc_file, summary, source, sea_name, p_lat,
c:\tamoc-master\tamoc\ambient.py:1858: in create_nc_db
nc = model_share.tamoc_nc_file(nc_file, title, summary, source)
c:\tamoc-master\tamoc\model_share.py:65: in tamoc_nc_file
nc = Dataset(fname, 'w', format='NETCDF4_CLASSIC')
src\netCDF4_netCDF4.pyx:2463: in netCDF4._netCDF4.Dataset.init
???
________________________________
???
E PermissionError: [Errno 13] Permission denied: b'C:\tamoc-master\tamoc\test\output\test_BM54.nc'
src\netCDF4_netCDF4.pyx:2026: PermissionError
________________________________
________________________________
The differences seem to be in an order of 1e3 and I am suspicious that there might be a wrong conversion factor somewhere. Any help is welcome, as I am am not very used in python.
—
Reply to this email directly, view it on GitHub<https://urldefense.com/v3/__https://github.com/socolofs/tamoc/issues/19__;!!KwNVnqRv!EnLU78CO-X2O3eUhxvhbhPI7Wo6I5ah94IdOc8K4s9beteCFQ8o-3gVh6WmY-gz3RmzuZ1CLAkzX5M7vx5GeDWb3PQ$>, or unsubscribe<https://urldefense.com/v3/__https://github.com/notifications/unsubscribe-auth/AA6XESB76QERZQROCTVIJBTWHSYANANCNFSM6AAAAAAR4JOFNE__;!!KwNVnqRv!EnLU78CO-X2O3eUhxvhbhPI7Wo6I5ah94IdOc8K4s9beteCFQ8o-3gVh6WmY-gz3RmzuZ1CLAkzX5M7vx5EAGASBgg$>.
You are receiving this because you are subscribed to this thread.
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi
I finally managed to get tamoc installed on a windows machine. I can not use miniconda, thus I followed the manual installation procedure and installed the latest development version 2.4.0 (hint: avoid spaces in the path!) - I could not get it to work with my default IBM Fortran compiler, thus I choose to install the --python-only version. When i run the test I get a couple of assertion errors (and some deprecated warnings, that I could resolve):
NumPy: 1.23.4
SciPy : 1.9.3
Matplotlib: 3.6.2
netCDF4 : 1.6.1
xarray : 2022.10.0
C:\temp>pytest -v --pyargs tamoc
================================================= test session starts =================================================
platform win32 -- Python 3.10.7, pytest-7.2.0, pluggy-1.0.0 -- C:\Python\Python310\python.exe
cachedir: .pytest_cache
rootdir: C:\temp
plugins: anyio-3.6.2
=============================================== short test summary info ===============================================
FAILED test/test_blowout.py::test_simulate - AssertionError:
FAILED test/test_bpm.py::test_plume_objs - AssertionError:
FAILED test/test_bpm.py::test_simulate - AssertionError:
FAILED test/test_bpm.py::test_files - AssertionError:
FAILED test/test_sbm.py::test_ic - PermissionError: [Errno 13] Permission denied: b'C:\tamoc-master\tamoc\test\output\test_BM54.nc'
FAILED test/test_spm.py::test_plume_objs - PermissionError: [Errno 13] Permission denied: b'C:\tamoc-master\tamoc\test\output\test_BM54.nc'
=============================== 6 failed, 69 passed, 286 warnings in 100.92s (0:01:40) ================================
E AssertionError:
E Items are not equal to 6 significant digits:
E ACTUAL: 0.0012566370614359175
E DESIRED: 1.29037789
c:\tamoc-master\tamoc\test\test_blowout.py:471: AssertionError
E AssertionError:
E Arrays are not almost equal to 6 decimals
E
E Mismatched elements: 1 / 1 (100%)
E Max absolute difference: 4.35702798
E Max relative difference: 0.99902754
E x: array([0.004241])
E y: array([4.361269])
c:\tamoc-master\tamoc\test\test_bpm.py:501: AssertionError
E AssertionError:
E Items are not equal to 6 significant digits:
E ACTUAL: 0.004241150082346221
E DESIRED: 4.36126914
c:\tamoc-master\tamoc\test\test_bpm.py:270: AssertionError
and some access permission error regarding netCDF:
c:\tamoc-master\tamoc\test\test_sbm.py:254:
c:\tamoc-master\tamoc\test\test_sbm.py:99: in get_profile
nc = make_ctd_file()
c:\tamoc-master\tamoc\test\test_sbm.py:76: in make_ctd_file
test_ambient.test_from_ctd()
c:\tamoc-master\tamoc\test\test_ambient.py:411: in test_from_ctd
nc = check_nc_db(nc_file, summary, source, sea_name, p_lat,
c:\tamoc-master\tamoc\test\test_ambient.py:100: in check_nc_db
nc = ambient.create_nc_db(nc_file, summary, source, sea_name, p_lat,
c:\tamoc-master\tamoc\ambient.py:1858: in create_nc_db
nc = model_share.tamoc_nc_file(nc_file, title, summary, source)
c:\tamoc-master\tamoc\model_share.py:65: in tamoc_nc_file
nc = Dataset(fname, 'w', format='NETCDF4_CLASSIC')
src\netCDF4_netCDF4.pyx:2463: in netCDF4._netCDF4.Dataset.init
???
src\netCDF4_netCDF4.pyx:2026: PermissionError
The differences seem to be in an order of 1e3 and I am suspicious that there might be a wrong conversion factor somewhere. Any help is welcome, as I am am not very used in python.
The text was updated successfully, but these errors were encountered: