Relation between Module, Package, Library, Framework in Python

1. Module


A module in Python is a collection of functions and global variables having a .py extension. Eg: Date time, Regex, Random, etc.

2. Package


A package in Python is a collection of various modules. The package also contains sub-packages inside it. Eg: NumPy, Pandas, etc.

3. Library


A library in Python is a collection of various packages which help to perform tasks without writing the code. It can be re-used and can be used just by importing it into the program. Eg: Matplotlib, Seaburn, etc.

4. Framework

A Python framework is a comprehensive collection of modules and packages designed to accelerate the development process.

Unlike libraries, frameworks are more intricate and provide a structured foundation and architectural guidelines for building applications.

Popular Posts

Conducting Polymers: Definition, Examples, Properties and Applications

Crime Scene: Definition, Types and Characteristics

Raman Spectroscopy: Principle, Instrumentation and Applications