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

failed to install #15

Open
hshsCollier-40hrs opened this issue May 14, 2022 · 4 comments
Open

failed to install #15

hshsCollier-40hrs opened this issue May 14, 2022 · 4 comments

Comments

@hshsCollier-40hrs
Copy link

hshsCollier-40hrs commented May 14, 2022

hello, im learning your library. I'm facing a problem now and I'm feeling so bad. after running pip install ecg-qc, I cannot import it.
the error says:
import ecg_qc
Traceback (most recent call last):
File "", line 1, in
import ecg_qc
ModuleNotFoundError: No module named 'ecg_qc'

so I find the folder, there's no folder 'ecg_qc' but just a folder 'ecg_qc-1.0b6.dist-info'. So I tried the next way, run '$ git clone https://github.com/Aura-healthcare/ecg_qc.git
$ python setup.py install' after some errors and solutions, the terminal says 'Finished processing dependencies for ecg-qc==1.0b6'. I was happy to see it, there is a 'ecg_qc-1.0b6-py3.8.egg' near the folder 'ecg_qc-1.0b6.dist-info'. im happy to see it.
BUT, when I try to run 'ecg_qc = EcgQc(model='rfc_norm_2s.pkl',
sampling_frequency=256,
normalized=True)'
it says: 'ecg_qc = EcgQc(model='rfc_norm_2s.pkl',
TypeError: init() got an unexpected keyword argument 'model''
so I delete the model, and run the rest of the sentence.
but It says, 'FileNotFoundError: [Errno 2] No such file or directory: 'rfc_norm_2s.pkl''
if I download the folder'ecg_qc' from github and paste it on the correct path, there's still the same error.
so I guess there's still something wrong with the installing.
I tried both on Mac and windows, all failed.
I'm so confused. what should I do? how to install the package successfully? please tell me, thank you very much.

@hshsCollier-40hrs
Copy link
Author

hshsCollier-40hrs commented May 15, 2022

hello author, I find that the function should be sqi_scores = ecg_qc.compute_sqi_scores(signal),not sqi_scores = ecg_qc.compute_sqi_score(signal).
and also
ecg_qc = EcgQc('rfc_norm_2s.pkl', sampling_frequency=fs, normalized=True)
don't have to write 'model =' before the model name.
I'm ok now, I don't have other questions. I just hope you can fix the pip install problem, so that will not affect others to use it.
Finally, I want to say, thank you for your efforts. My English is not very good. Please forgive me.

@Roneival
Copy link

i totally agree with you, had to work around the functions to get a result !
I guess that pip install is now fixed :)

@adgilbert
Copy link

I had the same issues... you have to use model_file when calling EcgQc.

I tried to fix the install issue in #16

@rdyan0053
Copy link

I have same error:
ImportError: cannot import name 'EcgQc' from 'ecg_qc'

But I had install the ecg_qc by using the pip install ecg-qc on Linux server

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

4 participants