def lineno(loc,strg):
    return strg.count("\n",0,loc) + 1
Sorts a grid by the x0 location.
dataset/ETHPy150Open ipython/ipython-py3k/IPython/external/pyparsing/_pyparsing.py/lineno--crossover with--dataset/ETHPy150Open simpeg/simpeg/SimPEG/Mesh/TreeMesh.py/SortGrid