def asbytes(s):
    if isinstance(s, str):
        s = s.encode('ascii')
    return s
Scales the vector to be length 1.
dataset/ETHPy150Open ipython/ipython-py3k/IPython/parallel/util.py/asbytes--crossover with--dataset/ETHPy150Open PythonProgramming/Beginning-Game-Development-with-Python-and-Pygame/Chapter 10/gameobjects/vector3.py/Vector3.normalise