  Properties of $\Lambda,~\Xi^0$ hypernuclei and neutron stars are investigated
in quark mean field model with pion and gluon corrections. Firstly, $u, ~d$,
and $s$ quarks are confined by relativistic harmonic oscillator potentials to
generate the baryons, like nucleon, $\Lambda, ~\Sigma$, and $\Xi$ hyperons. The
effects of pion-quark coupling and one-gluon exchange are considered
perturbatively. Then, the baryons interact with each other through exchanging
$\sigma, ~\omega,$ and $\rho$ mesons between quarks in hypernuclei and nuclear
matter. The strengths of confinement potentials for $u, ~d,$ and $s$ quarks are
determined by the masses and radii of free baryons. The coupling constants
between the quarks and mesons are fixed by the ground-state properties of
several nuclei and single-hyperon potentials at nuclear saturation density,
which arises three parameter sets for the coupling constants between mesons and
quarks, named QMF-NK1S, QMF-NK2S, and QMF-NK3S. Compared to the results of
previous quark mean field model without pion and gluon corrections, it is found
that properties of $\Lambda$ hypernuclei, i.e. the single $\Lambda$ energies,
are more consistent with the experimental observables. Properties of $\Xi^0$
hypernuclei are also calculated and compared with the results in previous quark
mean field model. With these three parameter sets, the neutron stars containing
hyperons are investigated through solving the Tolman-Oppenheimer-Volkoff
equation. Maximum masses of neutron stars approach $2.1M_\odot$ with hyperons
and corresponding radii are around $13$ km.
