  In astronomy, neural networks are often trained on simulation data with the
prospect of being used on telescope observations. Unfortunately, training a
model on simulation data and then applying it to instrument data leads to a
substantial and potentially even detrimental decrease in model accuracy on the
new target dataset. Simulated and instrument data represent different data
domains, and for an algorithm to work in both, domain-invariant learning is
necessary. Here we employ domain adaptation techniques$-$ Maximum Mean
Discrepancy (MMD) as an additional transfer loss and Domain Adversarial Neural
Networks (DANNs)$-$ and demonstrate their viability to extract domain-invariant
features within the astronomical context of classifying merging and non-merging
galaxies. Additionally, we explore the use of Fisher loss and entropy
minimization to enforce better in-domain class discriminability. We show that
the addition of each domain adaptation technique improves the performance of a
classifier when compared to conventional deep learning algorithms. We
demonstrate this on two examples: between two Illustris-1 simulated datasets of
distant merging galaxies, and between Illustris-1 simulated data of nearby
merging galaxies and observed data from the Sloan Digital Sky Survey. The use
of domain adaptation techniques in our experiments leads to an increase of
target domain classification accuracy of up to ${\sim}20\%$. With further
development, these techniques will allow astronomers to successfully implement
neural network models trained on simulation data to efficiently detect and
study astrophysical objects in current and future large-scale astronomical
surveys.

Instrumentation and Methods for Astrophysics;Astrophysics of Galaxies;Artificial Intelligence;Computer Vision and Pattern Recognition;Machine Learning