The Relationship Between Lyman-Alpha Opacity Of The Intergalactic Medium And Galaxy Density Near The End Of Reionization