A Janesville man who fired three shots into the air as police chased him the night of July 4 was sentenced Thursday in federal court to nearly four years in prison.

Antonio D. Sims, 39, of 255 S. Jackson St., No. 4, Janesville, was sentenced to 46 months behind bars after he was convicted of being a felon in possession of a firearm by Judge James Peterson, chief judge of the U.S. District Court for the Western District of Wisconsin.

“You’re not a completely irredeemable person; you just do stupid, dangerous things,” Peterson told Sims.

Sims was celebrating Independence Day with his family at his boss’s residence on South Academy Street when police responded to a threat complaint, according to the criminal complaint.

Janesville police questioned Sims, who fit the description of a man called “Rocky.” Sims denied he was “Rocky” and fled when an officer tried to detain him, according to the complaint.

Two officers were about 10 feet behind Sims when he pulled a .40-caliber handgun from his waistband and fired three shots into the air, according to the complaint.

Sims fled to Mesa, Arizona, but police recovered three shell casings, his cellphone and his wallet. U.S. marshals arrested him in Arizona on July 10.

Sims is prohibited from carrying a gun because he has 18 convictions, including five felonies, since he turned 17.

At his sentencing Thursday, Sims told Peterson that he got a gun because of a threat from his neighbors. He said he carried it July 4 because people at a “biker clubhouse” were yelling racial epithets at him.

Sims said neither he nor his daughter had encountered racism before moving to Janesville from Joliet, Illinois, in 2017.

Peterson told Sims he made a bad decision by carrying a gun.

“I think you put yourself more at risk by having a gun than not having one,” the judge said.

Sims said he got scared when police showed up to question him.

“I just didn’t think,” he said “… I just ran.”

During his last arrest eight years ago, Sims said he was severely beaten by law enforcement in Joliet. A CT scan at a hospital revealed that Sims had sustained a traumatic brain injury, his attorney, Kelly Welsh, wrote to the court.

Running from police might seem nonsensical to some, but not to an African American man who has been a victim of excessive force, Welsh wrote.

“He didn’t intend to harm anybody,” Welsh told Peterson.

Sims apologized for his actions, which could have prompted officers to shoot him.

U.S. Attorney Scott Blader recommended a sentence of 51 months in prison. He told Peterson that Sims’ offense wasn’t the typical felon-in-possession case because it involved firing a gun while running down a residential street.

Peterson agreed that Sims needed a “stout sentence” because of the risk he posed to the community. But he said he would impose a 46-month sentence because Sims had kept out of trouble for the past several years.