Text this: Deep learning to ternary hash codes by continuation