Non-Fermi liquid physics is ubiquitous in strongly correlated metals, manifesting itself in anomalous transport properties, such as a T-linear resistivity in experiments. However, its theoretical understanding in terms of microscopic models is lacking, despite decades of conceptual work and attempted numerical simulations. Here we demonstrate that a combination of sign-problem-free quantum Monte Carlo sampling and quantum loop topography, a physics-inspired machine-learning approach, can map out the emergence of non-Fermi liquid physics in the vicinity of a quantum critical point (QCP) with little prior knowledge. Using only three parameter points for training the underlying neural network, we are able to robustly identify a stable non-Fermi liquid regime tracing the fans of metallic QCPs at the onset of both spin-density wave and nematic order. In particular, we establish for the first time that a spin-density wave QCP commands a wide fan of non-Fermi liquid region that funnels into the quantum critical point. Our study thereby provides an important proof-of-principle example that new physics can be detected via unbiased machine-learning approaches.