# Top 10 Python Packages you should try right now

Python has various packages to make your life easy so that you don't need to code from scratch. These are some of the packages which you can use to build your next project in Python.



## PDF Miner 
```
pip install pdfminer
```

**[PDF Miner ](https://github.com/euske/pdfminer) ** lets you extract text from pdf files. This can be useful if you are building a product which needs text from say resumes or reports.

![https://cdn.hashnode.com/res/hashnode/image/upload/v1601567476205/gEMzqA16J.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1601567476205/gEMzqA16J.png)

There is also a similar library called **[PyreParser ](https://github.com/OmkarPathak/pyresparser) ** which is specially made just for extracting resume information(This tech is pretty much used in every company in the hiring process)
*** 


## Pillow
```
pip install Pillow==2.2.1
```
** [Pillow](https://github.com/python-pillow/Pillow)  ** is a library which allows for image manipulation & conversion. You can do a wide variety of things like adding text to an image or blurring an image. Below is a simple example of adding text to an image.

![https://cdn.hashnode.com/res/hashnode/image/upload/v1601567416894/lZZwHPh8p.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1601567416894/lZZwHPh8p.png)
Below is the before and after running this code. We just added "hashnode is amazing" in the bottom right using the x y coordinates.

![New Project(1).png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602186397002/p9xKUVxh5.png)

There is also a python package called ** [moviepy](movie) ** which lets you do similar things but with videos.

---


## OpenCV

```python
pip install opencv-python
```

![image.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602215251451/FTsTOiPzs.png)

This is one of the booming packages and LinkedIn is filled with project demos built with OpenCV. You can do anything from resizing an image to Controlling Subway surfers from your hands through image recognition. 


![carbon(12).png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602172874634/Pzr3fVlCg.png)

Above is a simple example to open a greyscale image and resize it.

Refer to these Resources to learn more about OpenCV( [Edureka](https://www.edureka.co/blog/python-opencv-tutorial/) 
and [Murtazas YouTube Channel](https://www.youtube.com/c/MurtazasWorkshopRoboticsandAI) )

---

## Furl

```
pip install furl
```

[Furl](https://github.com/gruns/furl) makes parsing and manipulating URLs easy for you. Here is an example of paths and query using furl 


![carbon(7).png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602172475271/YzWB1Gpjn.png)

Output:

```python
http://www.google.com/path?two=2&three=3
```
*** 

## Scikit- learn
```
pip install scikit-learn
```
**Scikit- learn** can be used for a variety of applications which include classification, regression, clustering, model selection, naive Bayes’, grade boosting, K-means, and preprocessing.

![carbon(14).png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602186441729/tVTIFwkbr.png)
Above is a snippet from one of my 2nd-year projects at engineering which predicts prices for houses in Bangalore. This uses Linear Regression and I didn't know the formula and other details but using scikit-learn I could easily use the concept to build a model.


## Html2Text

```
pip install html2text
```

This allows you to convert HTML code to markdown with just one line of python code.  
But you can't directly add websites instead of HTML code, using a beautiful soup can help you do that. 

![https://cdn.hashnode.com/res/hashnode/image/upload/v1601567238934/El7D8Tr6j.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1601567238934/El7D8Tr6j.png)

**Output** :

```markdown
#  Hello world

**Html2 text is amazing**

[ My Blogs are cool ](blog.hrithwik.me/)
```

---

## Beautiful Soup
```
pip install beautifulsoup4
```
**Beautiful Soup** allows you to parse HTML data from websites and get the data you want by finding the element you want using id or class name. This is one of the most used tools in the field of web scraping. (NOTE: Web Scrapping might be illegal on some websites )


![carbon(8).png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602172933926/YFDvKh1jb.png)


Here We just parsed through @[Bhanu's](@pbteja1998) Article and Generated a markdown from the URL using  [HTML2Text](#html2text)

---

## Kivy
```
pip install kivy==1.11.1
```
 [Kivy](https://kivy.org/doc/stable-1.10.1/installation/installation.html)  is a really interesting GUI framework that you can use to create desktop user interfaces and mobile applications on both iOS and Android.

 Kivy applications will not look like native apps on any platform. This can be an advantage if you want your application to look and feel different from the competition. There are even some alternatives like PyQt and Quirt.


![carbon(9).png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602172834173/5hqHM65XE.png)

*** 

## Faker

```python
pip install Faker

```

Faker is a Python package that generates fake data for you. This can be really useful for testing or bootstrapping your database.



![carbon(10).png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602186490378/cAKYe-5sY.png)

You can even checkout [radar](https://pypi.org/project/radar/) which can generate random date and time.

## Selenium

```python
pip install selenium  

```

Selenium is one of the testing frameworks which can be used for fun stuff like automation and building bots. You can automate anything like sending WhatsApp messages to increasing views for your blog.

![carbon(11).png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602172635341/2Iv8kHbMT.png)

This is a code which opens your website for n number of times in a browser. You can add different user-agents as well. 



--- 
## Conclusion

These were some packages which can do testing or build machine learning projects. Try using any one of them and let me know what you built using these Packages. Hit me up on [Twitter](https://twitter.com/HSBTechYt) or  [Linkedin ](https://www.linkedin.com/in/hrithwik-bharadwaj-a77810150/).

![hrithwik.jpg](https://cdn.hashnode.com/res/hashnode/image/upload/v1599034192769/tdRNTK_i9.jpeg)


