<s> from math import sqrt , pi <EOL> from numpy import zeros , tile , exp <EOL> from numpy . core . umath_tests import inner1d <EOL> __all__ = ( '<STR_LIT>' , ) <EOL> def pdf_between_data ( train_data , input_data , std ) : <EOL> """<STR_LIT>""" <EOL> results = zeros ( ( train_data . shape [ <NUM_LIT:0> ] , input_data . shape [ <NUM_LIT:0> ] ) ) <EOL> variance = std ** <NUM_LIT:2> <EOL> function_const = std * sqrt ( <NUM_LIT:2> * pi ) <EOL> train_data_size = train_data . shape [ <NUM_LIT:0> ] <EOL> for i , input_row in enumerate ( input_data ) : <EOL> inputs = tile ( input_row , ( train_data_size , <NUM_LIT:1> ) ) <EOL> class_difference = ( train_data - inputs ) <EOL> total_distance = inner1d ( class_difference , class_difference ) <EOL> results [ : , i ] = exp ( - total_distance / variance ) / function_const <EOL> return results </s>
