Skip to content

Instantly share code, notes, and snippets.

@AadityaJ
Created October 1, 2016 20:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AadityaJ/bc0ee89abf83bbc238b01777ac79b626 to your computer and use it in GitHub Desktop.
Save AadityaJ/bc0ee89abf83bbc238b01777ac79b626 to your computer and use it in GitHub Desktop.
Provides basics for later scikit learn interface implementation. File structure
"""
scikit learn interface for gensim for easy use of gensim with scikit-learn
"""
class BaseClass(object):
def __init__(self):
"""init"""
def run(self):
return 0
"""scikit learn wrapper for gensim
Contains various gensim based implementations
which match with scikit-learn standards .
See [1] for complete set of conventions.
[1] http://scikit-learn.org/stable/developers/
"""
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright (C) 2010 Radim Rehurek <radimrehurek@seznam.cz>
# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html
"""
Tests for sklearn_integration interface
"""
import logging
import unittest
import os
import os.path
from gensim.sklearn_integration import base
class TestSklearn(unittest.TestCase):
"""
write test script
"""
#for now
def testRun(self):
model=base.BaseClass()
self.assertEquals(model.run(),0)
if __name__ == '__main__':
logging.basicConfig(format='%(asctime)s : %(levelname)s : %(message)s', level=logging.DEBUG)
unittest.main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment