Tag optimizing neural networks via koopman operator theory