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

Wrong results in Test MHKiT-Python installation #295

Closed
jiqiaoling opened this issue Mar 15, 2024 · 3 comments
Closed

Wrong results in Test MHKiT-Python installation #295

jiqiaoling opened this issue Mar 15, 2024 · 3 comments
Assignees
Labels
documentation Improvements or additions to documentation

Comments

@jiqiaoling
Copy link

jiqiaoling commented Mar 15, 2024

I installed the MHKiT-Python following the guide. But when I test the installation as the method in the guide, with the command as following:
[ED, AP] = mhkit.river.performance.circular(30)
print(ED)
print(AP)
the results in my computer are:
30
706.8583470577034
This is not the correct result, it should be as the guide:
ED = 30
AP = 11309.7
We don't know what is wrong, any help would be pleased.

addition:
We use python 3.8 and anaconda3, the install information of mhkit in our computer is as following 👍
Requirement already satisfied: mhkit in d:\anaconda\lib\site-packages (0.7.0)
Requirement already satisfied: pandas<=1.5.0,>=1.0.0 in d:\anaconda\lib\site-packages (from mhkit) (1.5.0)
Requirement already satisfied: numpy>=1.21.0 in d:\anaconda\lib\site-packages (from mhkit) (1.23.5)
Requirement already satisfied: scipy in d:\anaconda\lib\site-packages (from mhkit) (1.10.1)
Requirement already satisfied: matplotlib in d:\anaconda\lib\site-packages (from mhkit) (3.3.2)
Requirement already satisfied: requests in d:\anaconda\lib\site-packages (from mhkit) (2.24.0)
Requirement already satisfied: pecos>=0.1.9 in d:\anaconda\lib\site-packages (from mhkit) (0.3.1)
Requirement already satisfied: fatpack in d:\anaconda\lib\site-packages (from mhkit) (0.7.7)
Requirement already satisfied: lxml in d:\anaconda\lib\site-packages (from mhkit) (4.6.1)
Requirement already satisfied: scikit-learn in d:\anaconda\lib\site-packages (from mhkit) (0.23.2)
Requirement already satisfied: NREL-rex>=0.2.63 in d:\anaconda\lib\site-packages (from mhkit) (0.2.79)
Requirement already satisfied: six>=1.13.0 in d:\anaconda\lib\site-packages (from mhkit) (1.15.0)
Requirement already satisfied: h5py>=3.6.0 in d:\anaconda\lib\site-packages (from mhkit) (3.10.0)
Requirement already satisfied: h5pyd<=0.10.3,>=0.7.0 in d:\anaconda\lib\site-packages (from mhkit) (0.10.3)
Requirement already satisfied: netCDF4<=1.5.8 in d:\anaconda\lib\site-packages (from mhkit) (1.5.8)
Requirement already satisfied: xarray<=2022.9.0 in d:\anaconda\lib\site-packages (from mhkit) (2022.9.0)
Requirement already satisfied: statsmodels in d:\anaconda\lib\site-packages (from mhkit) (0.12.0)
Requirement already satisfied: pytz in d:\anaconda\lib\site-packages (from mhkit) (2020.1)
Requirement already satisfied: bottleneck in d:\anaconda\lib\site-packages (from mhkit) (1.3.2)
Requirement already satisfied: beautifulsoup4 in d:\anaconda\lib\site-packages (from mhkit) (4.9.3)
Requirement already satisfied: requests-unixsocket in d:\anaconda\lib\site-packages (from h5pyd<=0.10.3,>=0.7.0->mhkit) (0.3.0)
Requirement already satisfied: pyjwt in d:\anaconda\lib\site-packages (from h5pyd<=0.10.3,>=0.7.0->mhkit) (2.8.0)
Requirement already satisfied: msrestazure in d:\anaconda\lib\site-packages (from h5pyd<=0.10.3,>=0.7.0->mhkit) (0.6.4)
Requirement already satisfied: cryptography in d:\anaconda\lib\site-packages (from h5pyd<=0.10.3,>=0.7.0->mhkit) (3.1.1)
Requirement already satisfied: google-api-python-client in d:\anaconda\lib\site-packages (from h5pyd<=0.10.3,>=0.7.0->mhkit) (2.122.0)
Requirement already satisfied: google-auth-oauthlib in d:\anaconda\lib\site-packages (from h5pyd<=0.10.3,>=0.7.0->mhkit) (0.5.3)
Requirement already satisfied: google-auth<2.0dev in d:\anaconda\lib\site-packages (from h5pyd<=0.10.3,>=0.7.0->mhkit) (1.35.0)
Requirement already satisfied: adal in d:\anaconda\lib\site-packages (from h5pyd<=0.10.3,>=0.7.0->mhkit) (1.2.7)
Requirement already satisfied: cftime in d:\anaconda\lib\site-packages (from netCDF4<=1.5.8->mhkit) (1.6.3)
Requirement already satisfied: click>=7.0 in d:\anaconda\lib\site-packages (from NREL-rex>=0.2.63->mhkit) (7.1.2)
Requirement already satisfied: psutil>=5.6 in d:\anaconda\lib\site-packages (from NREL-rex>=0.2.63->mhkit) (5.7.2)
Requirement already satisfied: PyYAML in d:\anaconda\lib\site-packages (from NREL-rex>=0.2.63->mhkit) (5.3.1)
Requirement already satisfied: toml>=0.10.0 in d:\anaconda\lib\site-packages (from NREL-rex>=0.2.63->mhkit) (0.10.1)
Requirement already satisfied: python-dateutil>=2.8.1 in d:\anaconda\lib\site-packages (from pandas<=1.5.0,>=1.0.0->mhkit) (2.8.1)
Requirement already satisfied: jinja2 in d:\anaconda\lib\site-packages (from pecos>=0.1.9->mhkit) (2.11.2)
Requirement already satisfied: pytest in d:\anaconda\lib\site-packages (from pecos>=0.1.9->mhkit) (0.0.0)
Requirement already satisfied: packaging>=20.0 in d:\anaconda\lib\site-packages (from xarray<=2022.9.0->mhkit) (20.4)
Requirement already satisfied: soupsieve>1.2 in d:\anaconda\lib\site-packages (from beautifulsoup4->mhkit) (2.0.1)
Requirement already satisfied: certifi>=2020.06.20 in d:\anaconda\lib\site-packages (from matplotlib->mhkit) (2020.6.20)
Requirement already satisfied: cycler>=0.10 in d:\anaconda\lib\site-packages (from matplotlib->mhkit) (0.10.0)
Requirement already satisfied: kiwisolver>=1.0.1 in d:\anaconda\lib\site-packages (from matplotlib->mhkit) (1.3.0)
Requirement already satisfied: pillow>=6.2.0 in d:\anaconda\lib\site-packages (from matplotlib->mhkit) (8.0.1)
Requirement already satisfied: pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.3 in d:\anaconda\lib\site-packages (from matplotlib->mhkit) (2.4.7)
Requirement already satisfied: chardet<4,>=3.0.2 in d:\anaconda\lib\site-packages (from requests->mhkit) (3.0.4)
Requirement already satisfied: idna<3,>=2.5 in d:\anaconda\lib\site-packages (from requests->mhkit) (2.10)
Requirement already satisfied: urllib3!=1.25.0,!=1.25.1,<1.26,>=1.21.1 in d:\anaconda\lib\site-packages (from requests->mhkit) (1.25.11)
Requirement already satisfied: joblib>=0.11 in d:\anaconda\lib\site-packages (from scikit-learn->mhkit) (0.17.0)
Requirement already satisfied: threadpoolctl>=2.0.0 in d:\anaconda\lib\site-packages (from scikit-learn->mhkit) (2.1.0)
Requirement already satisfied: patsy>=0.5 in d:\anaconda\lib\site-packages (from statsmodels->mhkit) (0.5.1)
Requirement already satisfied: cachetools<5.0,>=2.0.0 in d:\anaconda\lib\site-packages (from google-auth<2.0dev->h5pyd<=0.10.3,>=0.7.0->mhkit) (4.2.4)
Requirement already satisfied: pyasn1-modules>=0.2.1 in d:\anaconda\lib\site-packages (from google-auth<2.0dev->h5pyd<=0.10.3,>=0.7.0->mhkit) (0.3.0)
Requirement already satisfied: setuptools>=40.3.0 in d:\anaconda\lib\site-packages (from google-auth<2.0dev->h5pyd<=0.10.3,>=0.7.0->mhkit) (50.3.1.post20201107)
Requirement already satisfied: rsa<5,>=3.1.4 in d:\anaconda\lib\site-packages (from google-auth<2.0dev->h5pyd<=0.10.3,>=0.7.0->mhkit) (4.9)
Requirement already satisfied: requests-oauthlib>=0.7.0 in d:\anaconda\lib\site-packages (from google-auth-oauthlib->h5pyd<=0.10.3,>=0.7.0->mhkit) (1.4.0)
Requirement already satisfied: cffi!=1.11.3,>=1.8 in d:\anaconda\lib\site-packages (from cryptography->h5pyd<=0.10.3,>=0.7.0->mhkit) (1.14.3)
Requirement already satisfied: httplib2<1.dev0,>=0.15.0 in d:\anaconda\lib\site-packages (from google-api-python-client->h5pyd<=0.10.3,>=0.7.0->mhkit) (0.22.0)
Requirement already satisfied: google-auth-httplib2>=0.1.0 in d:\anaconda\lib\site-packages (from google-api-python-client->h5pyd<=0.10.3,>=0.7.0->mhkit) (0.2.0)
Requirement already satisfied: google-api-core!=2.0.,!=2.1.,!=2.2.,!=2.3.0,<3.0.0.dev0,>=1.31.5 in d:\anaconda\lib\site-packages (from google-api-python-client->h5pyd<=0.10.3,>=0.7.0->mhkit) (2.10.2)
Requirement already satisfied: uritemplate<5,>=3.0.1 in d:\anaconda\lib\site-packages (from google-api-python-client->h5pyd<=0.10.3,>=0.7.0->mhkit) (4.1.1)
Requirement already satisfied: MarkupSafe>=0.23 in d:\anaconda\lib\site-packages (from jinja2->pecos>=0.1.9->mhkit) (1.1.1)
Requirement already satisfied: msrest<2.0.0,>=0.6.0 in d:\anaconda\lib\site-packages (from msrestazure->h5pyd<=0.10.3,>=0.7.0->mhkit) (0.7.1)
Requirement already satisfied: attrs>=17.4.0 in d:\anaconda\lib\site-packages (from pytest->pecos>=0.1.9->mhkit) (20.3.0)
Requirement already satisfied: iniconfig in d:\anaconda\lib\site-packages (from pytest->pecos>=0.1.9->mhkit) (1.1.1)
Requirement already satisfied: pluggy<1.0,>=0.12 in d:\anaconda\lib\site-packages (from pytest->pecos>=0.1.9->mhkit) (0.13.1)
Requirement already satisfied: py>=1.8.2 in d:\anaconda\lib\site-packages (from pytest->pecos>=0.1.9->mhkit) (1.9.0)
Requirement already satisfied: atomicwrites>=1.0 in d:\anaconda\lib\site-packages (from pytest->pecos>=0.1.9->mhkit) (1.4.0)
Requirement already satisfied: colorama in d:\anaconda\lib\site-packages (from pytest->pecos>=0.1.9->mhkit) (0.4.4)
Requirement already satisfied: pycparser in d:\anaconda\lib\site-packages (from cffi!=1.11.3,>=1.8->cryptography->h5pyd<=0.10.3,>=0.7.0->mhkit) (2.20)
Requirement already satisfied: googleapis-common-protos<2.0dev,>=1.56.2 in d:\anaconda\lib\site-packages (from google-api-core!=2.0.
,!=2.1.,!=2.2.,!=2.3.0,<3.0.0.dev0,>=1.31.5->google-api-python-client->h5pyd<=0.10.3,>=0.7.0->mhkit) (1.63.0)
Requirement already satisfied: protobuf!=3.20.0,!=3.20.1,!=4.21.0,!=4.21.1,!=4.21.2,!=4.21.3,!=4.21.4,!=4.21.5,<5.0.0dev,>=3.19.5 in d:\anaconda\lib\site-packages (from google-api-core!=2.0.,!=2.1.,!=2.2.*,!=2.3.0,<3.0.0.dev0,>=1.31.5->google-api-python-client->h5pyd<=0.10.3,>=0.7.0->mhkit) (4.25.3)
Requirement already satisfied: azure-core>=1.24.0 in d:\anaconda\lib\site-packages (from msrest<2.0.0,>=0.6.0->msrestazure->h5pyd<=0.10.3,>=0.7.0->mhkit) (1.30.1)
Requirement already satisfied: isodate>=0.6.0 in d:\anaconda\lib\site-packages (from msrest<2.0.0,>=0.6.0->msrestazure->h5pyd<=0.10.3,>=0.7.0->mhkit) (0.6.1)
Requirement already satisfied: pyasn1<0.6.0,>=0.4.6 in d:\anaconda\lib\site-packages (from pyasn1-modules>=0.2.1->google-auth<2.0dev->h5pyd<=0.10.3,>=0.7.0->mhkit) (0.5.1)
Requirement already satisfied: oauthlib>=3.0.0 in d:\anaconda\lib\site-packages (from requests-oauthlib>=0.7.0->google-auth-oauthlib->h5pyd<=0.10.3,>=0.7.0->mhkit) (3.2.2)
Requirement already satisfied: typing-extensions>=4.6.0 in d:\anaconda\lib\site-packages (from azure-core>=1.24.0->msrest<2.0.0,>=0.6.0->msrestazure->h5pyd<=0.10.3,>=0.7.0->mhkit) (4.10.0)
Note: you may need to restart the kernel to use updated packages.

@ssolson
Copy link
Contributor

ssolson commented Mar 15, 2024

Hello @jiqiaoling. Thank you for your interest in MHKiT.

Your current version is correct.

The guide you are using is out dated. Could you please link me exactly where you are pulling this guide from?

This bug was fixed following the issues identified here: #165 (comment) and was fixed in #236

@ssolson ssolson self-assigned this Mar 15, 2024
@ssolson ssolson added the documentation Improvements or additions to documentation label Mar 15, 2024
@ssolson
Copy link
Contributor

ssolson commented Mar 15, 2024

@jiqiaoling I found the issue in our docs.

Thank you so much for bringing this to our attention. I have created an issue here: MHKiT-Software/MHKiT#55

And we will address this in our next release.

@ssolson ssolson closed this as completed Mar 15, 2024
@jiqiaoling
Copy link
Author

jiqiaoling commented Mar 17, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants