  The stellar mass - halo mass relation provides a strong basis for connecting
galaxies to their host dark matter halos in both simulations and observations.
Other observable information, such as the density of the local environment, can
place further constraints on a given halo's properties. In this paper, we test
how the peak masses of dark matter halos and subhalos correlate with
observationally-accessible environment measures, using a neural network to
extract as much information from the environment as possible. For high mass
halos (peak mass $>10^{12.5} M_{\odot}$), the information on halo mass
contained in stellar mass - selected galaxy samples is confined to the $\sim$ 1
Mpc region surrounding the halo center. Below this mass threshold, nearly the
entirety of the information on halo mass is contained in the galaxy's own
stellar mass instead of the neighboring galaxy distribution. The overall
root-mean-squared error of the best-performing network was 0.20 dex. When
applied to only the central halos within the test data, the same network had an
error of 0.17 dex. Our findings suggest that, for the purposes of halo mass
inference, both distances to the $k$th nearest neighbor and counts in cells of
neighbors in a fixed aperture are similarly effective measurements of the local
environment.
