How to package sklearn python program to exe by py2exe? -


below python program sklearn @ windows (sgd.py):

import numpy np sklearn import linear_model x = np.array([[-1, -1], [-2, -1], [1, 1], [2, 1]]) y = np.array([1, 1, 2, 2]) clf = linear_model.sgdclassifier() clf.fit(x, y) 

and py2exe setup.py file

from distutils.core import setup import py2exe,sys  setup( console=["sgd.py"], options = {  'py2exe':{'includes': ['sklearn.linear_model.sgdclassifier']} } ) 

i want package sgd.py exe file. when run command below, error recursionerror: maximum recursion depth exceeded.

python setup.py py2exe 

and add sys.setrecursionlimit(4000) setup.py, python has stopped working.

any idea package sklearn program exe ?


Comments

Popular posts from this blog

resizing Telegram inline keyboard -

command line - How can a Python program background itself? -

php - "cURL error 28: Resolving timed out" on Wordpress on Azure App Service on Linux -