Threading

Added multithreading for batch NNs