I bet an artificial intelligence algorithm could easily do exactly that.
The program's only inputs should be population data and existing political boundaries. If race and party affiliation data were kept out of the program's input, you'd end up with a race-neutral, party-neutral redistricting. (Of course, the politicians would never go for that.)
Two things are certain. The state legislature should have nothing to do with political districts and district boundries should reflect geographic considerations, not political, cultiral or racial.
The coordinate data from the census, processeed by any of a mutitude of programs could redistrict without human interference.
The electorate simply has to have the will to say no to the legislature. The rest is so elementary that even a child evaulate the fairness of the results based on the shapes of the districts.