echonet / dynamic

EchoNet-Dynamic is a deep learning model for assessing cardiac function in echocardiogram videos.
https://echonet.github.io/dynamic
Other
482 stars 169 forks source link

ConvertDICMToAVI #29

Open 1995Emma opened 3 years ago

1995Emma commented 3 years ago

Thank you for the code, but I have two questions about the preprocessing code. 1.yCrop = np.where(mean<1)[0][0] in code #2,why the mean<1, what is the reason for chossing 1 instead of other numbers? 2.What is the function difference between #1 and #2? code#1smallOutput = outputA[int(height/10):(height - int(height/10)), int(height/10):(height - int(height/10))]

code#2 ``` frame0 = testarray[0] mean = np.mean(frame0, axis=1) mean = np.mean(mean, axis=1) yCrop = np.where(mean<1)[0][0] testarray = testarray[:, yCrop:, :, :]

        bias = int(np.abs(testarray.shape[2] - testarray.shape[1])/2)
        if bias>0:
            if testarray.shape[1] < testarray.shape[2]:
                testarray = testarray[:, :, bias:-bias, :]
            else:
                testarray = testarray[:, bias:-bias, :, :]
milktea-1 commented 3 years ago

i used mean<1 on my dataset not work