IBM/helayers-examples

can you help me with this?

Closed this issue · 8 comments

image
A segmentation fault has occurred when I run the code in the mnist notebook,why would this happen?

aehud commented

Can you provide more details? Which version of pyhelayers are you using? Did you download the docker image or installed the pyhelayers library only? Where is the segmentation fault? On which machine are you running it?

My pyhelayers version is 1.5.3.0,I didn't download the docker image.
image
The fault occurred when I run the code in mnist notebook to this place,and I don't know why this wuold happen.
image

aehud commented

Thanks. These screen shots you attached seem to be warnings. I don't think they are related. Can you provide a screen shot of the segmentation fault?
Also, a common problem is memory issues. How much memory you have on the machine you are running this demo?
Do other demos work ok? E.g., demo 02_NeuralNetwork_fraud_detection or 01_FHE_basics ?

c5080c03edfe866bd8c5b391b690810
This is the chinese meaning of segmentation fault.It means segmentation fault(core dumped).After the code runs, there is only this one error message, no more prompts.My machine has 64 gigabytes of memory.Other demos work ok.

I have one more question. If the tile tensors are used in this mnist notebook.

aehud commented

Yes, tile tensors are used 'under the hood' whenever you load a neural network model or other models. They are used to represent the tensors that run through the network and the network weights.

Regarding the error:

  • Memory is still a suspect. Can you try another machine with more memory? Or perhaps check how much free memory you have on that machine? Perhaps not all 64GB of memory are free for the demo?
  • Can you provide more information on machine? Type of hardware, os, etc...
  • Can you add print(profile) before the crashing line context = pyhelayers.HeModel.create_context(profile)? Perhaps something is unusual in the object being passed to create_context.

Thanks for your help,I run it on docker and it works ok.