Movement of biological swarm exists widely in nature, and cooperative mechanism can improve the adaptability of the swarm to the environment. However, most current research studies free swarm movement and ignore analysis subject to environmental constraints like existence of tubes. In this paper, an experimental environment is set up such that Petitella georgiae swimming through a tube is studied. Based on the observation of position, speed, and direction of each fish, it is found out that each fish is affected by the distribution of fish swarm in its field of view. When a fish swarm swims through the tube, the ratio of speeds in middle region and edge region has a linear positive correlation with the cosine of angles the tube forms, and the average speed is larger within a specific angle range. When fish swarm passes through tubes, the area with a larger speed also corresponds to a larger density.