Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Colab finishes with a ^C

I'm running a laplacian pyramid program on Colab that is not vectorized so it takes it's time and when it gets to def vizpyramid() it just exits per below:

100% 1/1 [00:00<00:00, 23.74it/s]
def computestack
len grayimgs 2
gray_imgs[0] shape (500, 333)
len lapylpyrcolor 3, len lapylpyrcolor[0] 5
len lapylpyrcolor 3, len lapylpyrcolor[0] 5
fusedgray shape (500, 333)
def vizpyramid
^C

Most of those are from print statements except the 100%... and ^C. I did not push control-C so what is happening? I have checked the function and it works fine on my local machine.

Edit: I tried switching to a None no-GPU runtime and now it won't even run with a !python main.py command.

like image 876
mLstudent33 Avatar asked Nov 16 '19 09:11

mLstudent33


2 Answers

I met the same problem when I ran python in colab. I found that because the list I generated was too large, it should have occupied all the memory.

like image 70
tangxuemei Avatar answered Nov 19 '22 03:11

tangxuemei


"^C" appears for multiple types of interrupt in Colab I noticed. Even if you just press on the stop button (to interrupt execution of a cell) it shows "^C". I can't think of any other reasons why it would show a "^C"

like image 43
Michielver Avatar answered Nov 19 '22 05:11

Michielver