Can two New Yorkers share a turquoise Cadillac on a tour of the Deep South in the 1960s without driving each other crazy?

Apologies to the opening credits of the TV sitcom “The Odd Couple,” but that’s the pertinent question in “Green Book,” a different (yet familiar) odd-couple heartwarmer directed by Peter Farrelly — yes, the same Peter Farrelly of “Dumb and Dumber” fame, but this is a road movie of a completely different ilk.

A crowd-pleasing hit at the Toronto International Film Festival in September, the movie was “inspired by a true story” but may not be accurate history (welcome to the movies). Still, with actors as wily as Viggo Mortensen and Mahershala Ali, plus a ringer we’ll get to later, the quality of the material matters less than usual.

In 1962, African-American concert pianist and recording artist Don Shirley embarked on a concert tour of the Midwest and the South. Concerned about Shirley’s safety, his record label hired a driver: Tony Vallelonga — an Italian-American better known as “Tony Lip” around the Bronx and in the vicinity of the Copacabana nightclub, where he worked as a bouncer.

In many towns the performer was legally barred from staying in hotels that were open to whites. The AAA-style “Negro Motorist Green Book,” a guide to affordable lodging for black motorists traveling in institutionally segregated times, gives director Farrelly’s cheerfully fictionalized account its title.

To play Tony Lip, Mortensen bulked up considerably. When he’s behind the wheel of the ’62 Caddy, it’s like watching a big car driven by a slightly smaller one. Not known for broad or even subtle comedy (the movie favors the former), Mortensen works hard at behaving like a semblance of a real person in a real place and time. Some of the details catch your eye, such as the way he fishes a Lucky Strike out of a half-smoked pack while doing something else, or his method of folding an entire pizza into a handy wiseguy-sized bite.

The movie’s New York City sequences — which were shot in New Orleans — don’t look anything like the Big Apple, but we’re not in the land of realism here. Farrelly works well with the lead actors, but Tony’s friends and family skirt one sort of caricature, while the Dixie racists making the road tour difficult for Shirley and the Lip edge toward another.

“Green Book” relies almost entirely on the interplay between Mortensen and Ali. It’s a car-based journey of discovery, begun on a note of mutual wariness, ending on an affirmative flourish of true friendship. The movie sets its chosen tone at the beginning, establishing Tony’s ingrained, casual-seeming prejudice with lingering close-ups of Mortensen throwing away drinking glasses used by a couple of African-American repairmen working in the family kitchen.

While the movie charts the lovable lug’s enlightenment, Shirley remains a remote, diffident enigma — the fastidious, uptight Felix Unger to Mortensen’s Oscar Madison.

The lean toward Tony Lip and his universe is no surprise, given that the script comes from Nick Vallelonga (the real-life Tony’s son). On the other hand, all the attention paid to Tony gives the fabulous Linda Cardellini (TV’s “Mad Men”) as Tony’s wife some welcome screen time. The actress lends easy warmth and honestly earned sentiment to her performance, and when she, Ali and Mortensen finally share a scene in the finale, hearts will warm and tears will flow.

Farrelly knows a narrative gold mine when he sees one. And he knows enough to stay out of his actors’ way.