e73418dbc43053ccb522e94e9846de1c88667b73,trunk/SUAVE/Components/Energy/Networks/Propulsor_Surrogate.py,Propulsor_Surrogate,build_surrogate,#Propulsor_Surrogate#,73

Before Change


        col1 = my_data[1:,:1]
        col2 = my_data[1:,1:2]
        col3 = my_data[1:,2:3]
        for ii in xrange(0, len(col1)-1):
            if (col1[ii] == col1[ii+1])&(col2[ii] == col2[ii+1])&(col3[ii] == col3[ii+1]):
                np.delete(my_data,(ii), axis=0)

                

After Change


            //if (col1[ii] == col1[ii+1])&(col2[ii] == col2[ii+1])&(col3[ii] == col3[ii+1]):
                //np.delete(my_data,(ii), axis=0)

        b = np.ascontiguousarray(my_data).view(np.dtype((np.void, my_data.dtype.itemsize * my_data.shape[1])))
        _, idx = np.unique(b, return_index=True)
        
        my_data = my_data[idx]                
                
    
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: suavecode/SUAVE
Commit Name: e73418dbc43053ccb522e94e9846de1c88667b73
Time: 2017-04-01
Author: ebotero@stanford.edu
File Name: trunk/SUAVE/Components/Energy/Networks/Propulsor_Surrogate.py
Class Name: Propulsor_Surrogate
Method Name: build_surrogate


Project Name: tensorflow/hub
Commit Name: 20f388cfe01635a2073723c5c4ffd6dd7a87fbb2
Time: 2019-11-15
Author: cedric.renggli@gmail.com
File Name: tensorflow_hub/tools/module_search/utils.py
Class Name:
Method Name: knn_errorrate_loo


Project Name: tensorflow/hub
Commit Name: 20f388cfe01635a2073723c5c4ffd6dd7a87fbb2
Time: 2019-11-15
Author: cedric.renggli@gmail.com
File Name: tensorflow_hub/tools/module_search/utils.py
Class Name:
Method Name: knn_errorrate