-
Notifications
You must be signed in to change notification settings - Fork 78
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
how to predict with .edf file? #39
Comments
Hi, @Hunter0904 ! Predefined pipelines that you are using were designed to demonstrate how the library works on two specific tasks with specific datasets. If you take a look at You can use our pipelines as an example to develop those suited for your needs. E.g., to solve your current issue you can just replace |
@dpodvyaznikov Thank for your answer. |
You still can use the model you've trained with |
I will try it ~ |
I'll close this issue for now. |
I had tried this. It's worked. |
Dear all:
I have train a model with /example/Getting_started.jupyter
it's worked with .hea file
and it can predict hea file
but how to read .edf file
when I change lod .head file to .edf file
code:
index = bf.FilesIndex(path="../cardio/tests/data/sample.edf", no_ext=True, sort=True)
eds = bf.Dataset(index, batch_class=EcgBatch)
batch = eds.next_batch(batch_size=2)
batch_with_data = batch.load(fmt="edf", components=["signal", "meta"])
from cardio.pipelines import dirichlet_predict_pipeline
model_path = "af_model_dump"
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=0.7, allow_growth=True)
pipeline = dirichlet_predict_pipeline(model_path, gpu_options=gpu_options)
res = (eds >> pipeline).run()
pred = res.get_variable("predictions_list")
I get problem :
/usr/local/lib/python3.6/dist-packages/cardio/core/ecg_batch.py in _reraise_exceptions(self, results)
197 if bf.any_action_failed(results):
198 all_errors = self.get_errors(results)
--> 199 raise RuntimeError("Cannot assemble the batch", all_errors)
200
201 @staticmethod
RuntimeError: ('Cannot assemble the batch', [FileNotFoundError(2, 'No such file or directory')])
Plz help me~~
thanks a lot
The text was updated successfully, but these errors were encountered: