OKLAHOMA CITY — Despite some tough losses, including this week’s back-to-back defeats in Los Angeles, the Nets have made clear improvement on the court. And it’s resulting in improvement off the court.

Some of it is due to confidence and stability under new general manager Sean Marks, and part is the grit and effort the team has played with under coach Kenny Atkinson.

And much is a result of adding Jeremy Lin, who has one of the biggest profiles in the entire NBA.

“Fans seem to be very accepting, and not only accepting but are encouraged by the new culture, the grit with which the team plays and the hustle. And it’s leading to increased sales,’’ Brett Yormark, the CEO of Brooklyn Sports & Entertainment, the Nets’ parent company told The Post on Wednesday in Los Angeles. “They see the vision, see where this thing is going, and they’re happy with that direction.”

The Nets didn’t have much direction — other than possibly straight down — before Marks’ arrival. But fans have been engaged by their grit, and the addition of Lin, one of the biggest social media profiles in the entire NBA, has helped as well.

The Nets have signed a number of new commercial partners, with sources telling The Post a half-dozen of them came on board specifically because of Lin. Neither the NBA nor the Nets provided specific figures for Lin’s jersey sales, but sources in both the league and the team confirmed he’s the team’s leading seller.

Lin finished second in the NBA in jersey sales in 2012, essentially selling more in the three months of Linsanity with the Knicks than all but one NBA star had all season. No Net cracked the top 20 last season, but the uber-popular point guard did despite starting just 13 games for the Hornets in Charlotte, a city with less than one-tenth the population of New York.

This may not be Linsanity 2.0, but it’s hard to ignore.

“That’s creating the groundswell. It’s not where it needs to be, but the sales numbers indicate it’s heading in the right direction,’’ Yormark told The Post.

“We’re making real good progress. The culture Sean and Kenny bought started to resonate and we’re seeing it. And the team is validating that. You can see the team has bought in and is playing each game with commitment. And the fans are enjoying it.”

That’s showing across the board, from TV ratings to attendance to partnerships and social media.

Going into the sweep at Staples Center on Monday and Tuesday, the Nets’ ratings on YES were up 44 percent year-over-year, from 0.32 to 0.46. Their total viewers also were up 44 percent, and all of the key demographics had risen significantly. (They were up 44 percent in viewers 18-34, but only up 35 percent in men of that range, implying they have done exceptionally well with female fans).

Brooklyn also has seen encouraging signs at the gate. Attendance was down last season, and though it’s only up 2 percent, at 15,322, through the first five home dates compared to the same point last year, that 2015 stretch included a sellout for Kobe Bryant’s Barclays Center swan song and a game against the Celtics, who always draw in New York.

Lin is the first American of Taiwanese or Chinese descent to play in the NBA, and 200,000 of the city’s 570,000 residents of Chinese descent live in Brooklyn, so he has single-handedly changed the look of the crowd at Barclays Center.

“It’s fair to say our fan base is definitely becoming more diversified than ever before,’’ Yormark said.

That also pales in comparison to Lin’s worldwide appeal, composites showing he’s top five in the NBA in social-media impact. He has two million Twitter followers and twice as many likes on Facebook — and the Nets are catching that spillover.

The Nets’ Twitter engagement was up over 150 percent last month from the same point a year ago, and they currently have 685,000 followers. The engagement on Facebook had spiked 86 percent in the same span, and the Nets have gained 50,000 fans since the news of Lin’s signing broke in July.

Those stats — as well as the rest of their front-office numbers — just figure to go up.