Skip to content

Instantly share code, notes, and snippets.

View vtemian's full-sized avatar
🚀
-

Vlad Temian vtemian

🚀
-
View GitHub Profile
@vtemian
vtemian / flask.py
Last active August 29, 2015 14:02 — forked from horiajurcut/flask.py
import json
from functools import wraps
from flask import request
from utils.exceptions import HttpNotFound
from utils.validators import Required
def require(f):
@wraps(f)
/**
* From a file that contains
* doc_id w1 w2 w3 ... lines, separated by tabs
* return an inverted index Map of w -> Set(doc_id)
*
* @param filename well isn't it obvious
* @return Map[String,Set[String]]
*/
import scala.collection.immutable.Map