Skip to content

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

仓库 files navigation

lcx: 2020/01/06

This is a quick tutorial example to show how a python package is built.

  1. Structure of the package;
  2. Necessary files: setup.py, _init.py_.
  3. Specially, one needs to pay attention to the code in__init.py__.
from .Gaussiandistribution import Gaussian

With this line in _init.py_, one can use

from distribution import Gaussian

to import Gassian directly. Otherwise,

from distribution..Gaussiandistribution import Gaussian

关于

an example for build a python module

Topics

Resources

Stars

0 stars

关注者

1 watching

复刻s

发布

Used by

贡献者

Languages