Four inmates cut their way through the bars of a second-story window and rappelled down the side of a California jail using a makeshift rope of bedding and clothing before making their way clear of the facility, the Santa Clara County sheriff's office said Thursday.

Two of the men were recaptured just outside the jail after the Wednesday night escape, but the other two, Rogelio Chavez and Laron Campbell, remain on the lam, Sgt. Rich Glennon said.

Crime scene detectives were working to figure out how the men were able to cut through the window's bars. A deputy patrolling the jail's perimeter spotted the men as they made their escape.

"He kind of thought he saw some movement in the shadows looked up and saw some bedding in the window," Glennon told The Associated Press.

Both Chavez and Campbell were facing false imprisonment and weapons charges, among other counts, when they made their escape. Several agencies are searching for the men, with help from dogs and a helicopter using thermal imaging.

The men were last seen in their jail clothing, consisting of an orange top over gray bottoms. Chavez has a distinctive face tattoo that resembles an inky gash going through his left eye.

The recaptured men, whose names are not being released, are expected to face charges for the escape.

Glennon warned the public off approaching the men if they see them, but is asking people in the area to remain vigilant.

"We definitely don't want the community to approach these individuals, but be aware of anything suspicious," he said.