├── requirements.txt
├── database
├── First.json
└── data.json
├── img
├── PyLe.gif
└── PyLeGUI.jpg
├── PyLeGUI
├── PyLeGUI-PythonSource.zip
└── PyLeGUI-2.0(PythonSource).zip
├── imports
├── typer.py
├── libraries.py
├── Emails.py
├── search.py
├── other_libraries.py
└── Courses.py
├── AllVersions
└── Versions.txt
├── README.md
└── LICENSE
/requirements.txt:
--------------------------------------------------------------------------------
1 | colorama==0.4.4
2 |
--------------------------------------------------------------------------------
/database/First.json:
--------------------------------------------------------------------------------
1 | {"FirstTime": "True"}
2 |
--------------------------------------------------------------------------------
/img/PyLe.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AnonC0DER/PyLe/HEAD/img/PyLe.gif
--------------------------------------------------------------------------------
/img/PyLeGUI.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AnonC0DER/PyLe/HEAD/img/PyLeGUI.jpg
--------------------------------------------------------------------------------
/PyLeGUI/PyLeGUI-PythonSource.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AnonC0DER/PyLe/HEAD/PyLeGUI/PyLeGUI-PythonSource.zip
--------------------------------------------------------------------------------
/PyLeGUI/PyLeGUI-2.0(PythonSource).zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AnonC0DER/PyLe/HEAD/PyLeGUI/PyLeGUI-2.0(PythonSource).zip
--------------------------------------------------------------------------------
/imports/typer.py:
--------------------------------------------------------------------------------
1 | import time
2 | from colorama import Fore
3 | import random
4 |
5 | #colors class
6 | class colors:
7 | MAGENTA = Fore.LIGHTMAGENTA_EX
8 | YELLOW = Fore.LIGHTYELLOW_EX
9 | BLUE = Fore.LIGHTBLUE_EX
10 | RED = Fore.LIGHTRED_EX
11 | CYAN = Fore.LIGHTCYAN_EX
12 | WHITE = Fore.LIGHTWHITE_EX
13 |
14 |
15 | random_color = [colors.MAGENTA,colors.YELLOW,colors.RED,colors.BLUE,colors.CYAN,colors.WHITE]
16 | random.shuffle(random_color)
17 |
18 | class text_type:
19 |
20 | def __init__ (self, text):
21 | self.text = text
22 |
23 | def dprint(string):
24 | for letter in string:
25 | print(letter,end = '', flush=True)
26 | time.sleep(.06)
27 | print("")
28 |
29 | def printer(self):
30 | print = text_type.dprint
31 | print(random_color [0] + self.text)
--------------------------------------------------------------------------------
/AllVersions/Versions.txt:
--------------------------------------------------------------------------------
1 | Version 1.0:
2 | https://pyle-pythonlearning.ir/downloads/AllVersions/pyle%201.0.zip
3 |
4 | Version 1.1:
5 | https://pyle-pythonlearning.ir/downloads/AllVersions/PyLe%201.1.zip
6 |
7 | Version 1.5:
8 | https://pyle-pythonlearning.ir/downloads/AllVersions/PyLe%201.5.zip
9 |
10 | Version 1.6:
11 | https://pyle-pythonlearning.ir/downloads/AllVersions/PyLe 1.6.zip
12 |
13 | Version 2.0:
14 | https://pyle-pythonlearning.ir/downloads/AllVersions/PyLe 2.0.zip
15 |
16 | Version 2.1:
17 | https://pyle-pythonlearning.ir/downloads/AllVersions/PyLe%202.1.zip
18 |
19 | Version 2.5:
20 | https://pyle-pythonlearning.ir/downloads/AllVersions/PyLe%202.5.zip
21 |
22 | Version 3.0:
23 | https://pyle-pythonlearning.ir/downloads/AllVersions/PyLe%203.0.zip
24 |
25 | Version 3.2:
26 | https://pyle-pythonlearning.ir/downloads/AllVersions/PyLe%203.2.zip
27 |
28 | Version 3.5:
29 | https://pyle-pythonlearning.ir/downloads/AllVersions/PyLe%203.5.zip
30 |
--------------------------------------------------------------------------------
/imports/libraries.py:
--------------------------------------------------------------------------------
1 | # <------CoDed By AnonCODER------>
2 | # <------v2.5----->
3 | # <------Help me improve it :)------>
4 |
5 | from colorama import Fore
6 | import json
7 |
8 | # Open json data here
9 | fp = open('database/data.json', 'r')
10 | data = fp.read()
11 | fp.close()
12 |
13 | # All libraries :)
14 | class all_libraries():
15 |
16 | def __init__(self, install, lib, dec, exam, exam_site):
17 | self.install = install
18 | self.lib = lib
19 | self.dec = dec
20 | self.exam = exam
21 | self.exam_site = exam_site
22 |
23 | def AllLibs_install(self):
24 | print()
25 | print(Fore.YELLOW + '<---Installation--->')
26 | print(Fore.WHITE + f'pip install {self.install}')
27 | print(Fore.YELLOW + '<---Installation--->')
28 | print()
29 |
30 | def AllLibs_dec(self):
31 | print()
32 | print(Fore.YELLOW + '<---Description--->')
33 | print(Fore.WHITE + json.loads( data )[f'{self.lib}'][f'{self.dec}'])
34 | print()
35 | print(Fore.YELLOW + '<---Description--->')
36 | print()
37 |
38 | def AllLibs_exm(self):
39 | print()
40 | print(Fore.YELLOW + '<---Example--->')
41 | print(Fore.CYAN + f'More Details : {self.exam_site}')
42 | print(Fore.WHITE + json.loads( data )[f'{self.lib}'][f'{self.exam}'])
43 | print()
44 | print(Fore.YELLOW + '<---Example--->')
45 | print()
46 |
47 |
48 | # <------CoDed By AnonCODER------>
49 | # <------v2.5----->
50 | # <------Help me improve it :)------>
--------------------------------------------------------------------------------
/imports/Emails.py:
--------------------------------------------------------------------------------
1 | # <------CoDed By AnonCODER------>
2 | # <------v3.2----->
3 | # <------Now PyLe needs your support with its release------>
4 | # <------PyLe in Github : https://github.com/AnonC0DER/PyLe------>
5 | ##################################################################
6 | import smtplib
7 |
8 | # Send Email with PyLe Email Address
9 | class withPyLe_email():
10 |
11 | def __init__(self, Message):
12 | self.Message = Message
13 |
14 | def send_PyLeEmail(self):
15 | USER = 'pylesend.emails@gmail.com'
16 | # Please Don't Change the Password, it's for sending emails
17 | PASS = 'it3N0tAPassword'
18 |
19 | FROM = USER
20 | # My Email Address :
21 | To = ['anoncoder@tutanota.com']
22 | # Message :
23 | message_text = f'{self.Message}'
24 |
25 | server = smtplib.SMTP('smtp.gmail.com')
26 | server.connect('smtp.gmail.com',587)
27 | server.starttls()
28 | server.login(USER,PASS)
29 | server.sendmail(FROM, To, message_text)
30 | server.quit()
31 |
32 | # Send Email with Your own Email Address
33 | class yourOwn_email():
34 |
35 | def __init__(self, User, Password, Message):
36 | self.User = User
37 | self.Password = Password
38 | self.Message = Message
39 |
40 | def send_email(self):
41 | # Get email
42 | USER = f'{self.User}'
43 | # Get password
44 | PASS = f'{self.Password}'
45 |
46 | FROM = USER
47 | # My Email Address :
48 | To = ['anoncoder@tutanota.com']
49 | # Message :
50 | message_text = f'{self.Message}'
51 |
52 | server = smtplib.SMTP('smtp.gmail.com')
53 | server.connect('smtp.gmail.com',587)
54 | server.starttls()
55 | server.login(USER,PASS)
56 | server.sendmail(FROM, To, message_text)
57 | server.quit()
58 | ##################################
59 | # <------CoDed By AnonCODER------>
60 | # <------v3.2----->
61 | # <------Now PyLe needs your support with its release------>
62 | # <------PyLe in Github : https://github.com/AnonC0DER/PyLe------>
--------------------------------------------------------------------------------
/imports/search.py:
--------------------------------------------------------------------------------
1 | # imports
2 | import json
3 | from time import sleep
4 | from os import system
5 | from colorama import Fore
6 |
7 | # Open json data
8 | fp = open('database/data.json', 'r')
9 | data = fp.read()
10 | fp.close()
11 |
12 |
13 | # Search Class
14 | class Search:
15 |
16 | def __init__ (self, value):
17 | self.value = value
18 |
19 | # Search Function
20 | def search(self):
21 | system('clear')
22 | Data = self.value.lower()
23 | Data_correct = Data + '_dec'
24 | Search_Value = None
25 |
26 | # All json Datas
27 | json_data = json.loads( data )['Colors']
28 | json_data2 = json.loads( data )['Machin_Learning']
29 | json_data3 = json.loads( data )['Telegram_bots']
30 | json_data4 = json.loads( data )['game_devel']
31 | json_data5 = json.loads( data )['file_enc']
32 | json_data6 = json.loads( data )['sqllib']
33 | json_data7 = json.loads( data )['other']
34 |
35 | # first check
36 | if Data_correct in json_data:
37 | Search_Value = 'Colors'
38 |
39 | elif Data_correct in json_data2:
40 | Search_Value = 'Machin_Learning'
41 |
42 | elif Data_correct in json_data3:
43 | Search_Value = 'Telegram_bots'
44 |
45 | elif Data_correct in json_data4:
46 | Search_Value = 'game_devel'
47 |
48 | elif Data_correct in json_data5:
49 | Search_Value = 'file_enc'
50 |
51 | elif Data_correct in json_data6:
52 | Search_Value = 'sqllib'
53 |
54 | elif Data_correct in json_data7:
55 | Search_Value = 'other'
56 |
57 | # check for python_telegram_bot
58 | if Data == 'python_telegram_bot' or Data == 'python telegram bot' or Data == 'python telegram' or Data == 'telegram bot':
59 | print()
60 | print('<---Description--->')
61 | print(json.loads( data )['Telegram_bots']['python_telegram_bot_dec'])
62 | print()
63 | print('<---Description--->')
64 | print()
65 | show_examplePTB = input(Fore.LIGHTMAGENTA_EX + '[?] Do you wanna see an example ? (Y/N) : ')
66 | print()
67 | if show_examplePTB.upper() == 'Y':
68 | print()
69 | print(Fore.LIGHTYELLOW_EX + '<---Example--->')
70 | print()
71 | print(json.loads( data )['Telegram_bots']['python_telegram_bot_exm'])
72 | print()
73 | print(Fore.LIGHTYELLOW_EX + '<---Example--->')
74 | print()
75 |
76 | elif show_examplePTB.upper() == 'N':
77 | pass
78 |
79 | else:
80 | print(Fore.LIGHTRED_EX + '[!] Wrong Value')
81 |
82 |
83 | # Second check
84 | elif Data_correct in json_data or json_data2 or json_data3 or json_data4 or json_data5 or json_data6 or json_data7:
85 | print()
86 | print('<---Description--->')
87 | print(json.loads( data )[Search_Value][Data+'_dec'])
88 | print()
89 | print('<---Description--->')
90 | print()
91 | show_example = input(Fore.LIGHTMAGENTA_EX + '[?] Do you wanna see an example ? (Y/N) : ')
92 | print()
93 | if show_example.upper() == 'Y':
94 | print()
95 | print(Fore.LIGHTYELLOW_EX + '<---Example--->')
96 | print()
97 | print(json.loads( data )[Search_Value][Data+'_exm'])
98 | print()
99 | print(Fore.LIGHTYELLOW_EX + '<---Example--->')
100 | print()
101 |
102 | elif show_example.upper() == 'N':
103 | pass
104 |
105 | else:
106 | print(Fore.LIGHTRED_EX + '[!] Wrong Value')
107 |
108 | else:
109 | print(Fore.LIGHTRED_EX + '404 -> Not Found')
110 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | 
2 |
3 |
4 | # PyLe
5 | ## What's meaning of PyLe?
6 | > Learn and introduce Python libraries with PyLe.
7 | We all know that there are many Python libraries.
8 | Sometimes we have to go through a lot of problems to find the right library.
9 | There are many sites that introduce you to Python libraries.
10 | But their problem is that they can not introduce libraries with proper categories.
11 | PyLe is here to helps you !
12 | I have many ideas for PyLe, But I need to know someone knew my script.
13 | So, If you like PyLe idea, help me improve it :)
14 | > Version 4.0
15 |
16 | # Installation :
17 | Easy installation :
18 | - Linux :
19 | - git clone https://github.com/AnonC0DER/PyLe.git
20 | - Windows:
21 | - Use Cmder application (You can download it in PyLe)
22 |
23 | # Requirements :
24 | - python v3
25 | - pip install colorama
26 |
27 | <-------------------------------------->
28 |
29 | # PyLeRobot is ready (Telegram Robot)
30 | Now you can use PyLe in your telegram account !
31 | Easy & fast.
32 | > [PyLeRobot](https://t.me/PyLeRobot)
33 |
34 | # Updates News
35 | ## New Update 4.0 !
36 | - 7 new libraries in Other Section
37 | - Search function Added (Now You can search libraries in PyLe)
38 | - Quit Time Added
39 |
40 | ## New Update for PyLeGUI ! (Version 2.0)
41 | - Splash Screen Added !
42 | - Other section Added
43 | - 6 Libraries Added to Machine Learning Section
44 |
45 | #### [Download Version 2.0](https://github.com/AnonC0DER/PyLe#the-first-version-of-pyle-gui-is-ready-)
46 |
47 |
48 | > if You wanna know about next updates, please join PyLe's Telegram Channel.
49 | - https://t.me/PyLe_PythonLearning
50 |
51 |
52 | # The Second Version Of PyLe-GUI is Ready !
53 | ## Use PyQt5 For Version 1.0, PySide2 For Version 2.0 and pyinstaller for exe file.
54 | Please Send me your ideas for PyLe project.
55 | If there is any bug, [Let me know](https://github.com/AnonC0DER/PyLe#contact-me-).
56 | > (Tested On Windows 7,10 64bit)
57 |
58 |
59 | # Requirements for python source :
60 | - Version 2.0 = PySide2 (pip install PySide2)
61 | - Version 1.0 = PyQt5 (pip install PyQt5)
62 |
63 | <-------------------------------------->
64 |
65 | # All ideas :
66 | - [x] Use Json data for shorter code
67 | - [x] GUI Version
68 | - [x] PyLe WebSite
69 | - [X] Object-oriented programming
70 | - [X] FreeCourses section Added
71 | - [ ] Kind of suprise
72 |
73 |
74 | # Main Menu :
75 | ## Libraries :
76 | 1. Colors (Color output in Python)
77 | 2. Machine Learning
78 | 3. Telegram Robots
79 | 4. Game Development
80 | 5. File & Text Encryption
81 | 6. Python SQL Libraries
82 | 7. Other
83 |
84 | ## Colors :
85 | 1. => Colored
86 | 2. => Colorma
87 | 3. => Termcolor
88 |
89 | ## Machine Learning :
90 | 1. => Scikit-learn
91 | 2. => Keras
92 | 3. => Xgboost
93 | 4. => Statsmodels
94 | 5. => Tensorflow
95 | 6. => Numpy
96 | 7. => SciPy
97 | 8. => Matplotlib
98 | 9. => Seaborn
99 | 10. => PyTorch
100 | 11. => PyCaret
101 |
102 | ## Telegram Robots :
103 | 1. => Python-telegram-bot
104 | 2. => Pyrogram
105 | 3. => Telegram
106 |
107 | ## Game Development :
108 | 1. => Pygame
109 | 2. => Turtles
110 | 3. => PyOpenGL
111 |
112 | ## File & Text Encryption :
113 | 1. => Cryptography
114 | 2. => Pycrypto
115 | 3. => pyAesCrypt
116 |
117 | ## Python SQL Libraries :
118 | 1. => SQLite
119 | 2. => MySQL
120 | 3. => PostgreSQL
121 |
122 | ## Othres :
123 | 1. Os (Operating System)
124 | 2. Subprocess
125 | 3. Urllib Request
126 | 4. Requests
127 | 5. Tkinter
128 | 6. PyQt
129 | 7. MoviePy
130 | 8. datetime
131 | 9. Pendulum
132 | 10. Pillow
133 | 11. OpenCV Python
134 | 12. Theano
135 | 13. Fire
136 | 14. Arrow
137 | 15. FlashText
138 | 16. wxPython
139 | 17. Cirq
140 | 18. Json
141 | 19. Sys
142 | 20. InstaPy
143 | 21. Cython
144 | 22. pytube
145 | 23. Typer
146 | 24. Rich
147 | 25. Dear PyGui
148 | 26. PrettyErrors
149 | 27. Diagrams
150 | 28. HiPlot
151 | 29. Selenium
152 |
153 | ## Biginners & Professionals :
154 | 10. Books
155 | 90. What Is Python ?
156 | 91. Apps
157 |
158 | ## Tutorials :
159 | 92. Free Courses
160 |
161 | 20. GUI Version Of PyLe
162 | 1000. About Author
163 | 1001. License
164 | 1002. Update
165 | 1003. Send
166 | 1004. Exit
167 |
168 | <-------------------------------------->
169 | # Screenshot :
170 | 
171 | 
172 |
173 |
174 | # Contact me :
175 | > AnonCODER@tutanota.com
176 |
--------------------------------------------------------------------------------
/imports/other_libraries.py:
--------------------------------------------------------------------------------
1 | from colorama import Fore
2 | import json
3 |
4 | # Open The json Data
5 | fp = open('database/data.json', 'r')
6 | data = fp.read()
7 | fp.close()
8 | # Machine Learning Classes
9 | class machinlearning_class():
10 |
11 | def scikit_install():
12 | print ('')
13 | print(Fore.YELLOW + '<---Installation--->')
14 | print (Fore.WHITE + 'pip install scikit-learn')
15 | print(Fore.YELLOW + '<---Installation--->')
16 | print('')
17 |
18 | def scikit_dec():
19 | print('')
20 | print(Fore.YELLOW + '<---Description--->')
21 | print (Fore.WHITE + json.loads( data )['Machin_Learning']['scikit_dec'])
22 | print('')
23 | print (Fore.RED + json.loads( data )['Machin_Learning']['scikit_req'])
24 | print(Fore.YELLOW + '<---Description--->')
25 | print('')
26 |
27 | # pycaret
28 | def pycaret_install():
29 | print()
30 | print(Fore.YELLOW + '<---Installation--->')
31 | print(Fore.WHITE + 'pip install pycaret')
32 | print(Fore.YELLOW + '<---Installation--->')
33 | print()
34 |
35 | def pycaret_dec():
36 | print()
37 | print(Fore.YELLOW + '<---Description--->')
38 | print(Fore.WHITE + json.loads(data)['Machin_Learning']['pycaret_dec'])
39 | print()
40 | print(Fore.YELLOW + '<---Description--->')
41 | print()
42 |
43 | def pycaret_exm1():
44 | print()
45 | print(Fore.YELLOW + '<---Example--->')
46 | print(Fore.CYAN + 'More Details : https://pycaret.org/functions/')
47 | print(Fore.WHITE + json.loads(data)['Machin_Learning']['pycaret_exm1'])
48 | print()
49 | print(Fore.YELLOW + '<---Example--->')
50 | print()
51 | print(Fore.LIGHTGREEN_EX + 'There is another example do you wanna see it too? (Y/N)')
52 |
53 | def pycaret_exm2():
54 | print()
55 | print(Fore.YELLOW + '<---Example2--->')
56 | print(Fore.WHITE + json.loads(data)['Machin_Learning']['pycaret_exm2'])
57 | print()
58 | print(Fore.YELLOW + '<---Example2--->')
59 | print()
60 |
61 |
62 | # Telegram Bots
63 | class telegrambots_class():
64 |
65 | def Pyrogram_install():
66 | print ('')
67 | print(Fore.YELLOW + '<---Installation--->')
68 | print (Fore.WHITE + 'pip install Pyrogram')
69 | print(Fore.YELLOW + '<---Installation--->')
70 | print('')
71 |
72 | def Pyrogram_dec():
73 | print('')
74 | print(Fore.YELLOW + '<---Description--->')
75 | print(Fore.WHITE + json.loads( data )['Telegram_bots']['pyrogram_dec'])
76 | print(Fore.RED + json.loads( data )['Telegram_bots']['pyrogram_req'])
77 | print('')
78 | print(Fore.YELLOW + '<---Description--->')
79 | print('')
80 |
81 | def Pyrogram_exm():
82 | print('')
83 | print(Fore.YELLOW + '<---Example--->')
84 | print(Fore.CYAN + 'More Details : https://docs.pyrogram.org/start/examples/')
85 | print(Fore.WHITE + json.loads( data )['Telegram_bots']['pyrogram_exm'])
86 | print('')
87 | print(Fore.YELLOW + '<---Example--->')
88 | print('')
89 |
90 |
91 | # Other Class for other libraries, that i can't use libraries.py for them
92 | class other_class():
93 |
94 | def Os_dec():
95 | print()
96 | print(Fore.YELLOW + '<---Description--->')
97 | print(Fore.WHITE + json.loads( data )['other']['os_dec'])
98 | print()
99 | print(Fore.YELLOW + '<---Description--->')
100 | print()
101 |
102 | def Os_exm():
103 | print()
104 | print(Fore.YELLOW + '<---Example--->')
105 | print(Fore.CYAN + 'More Details : https://www.tutorialsteacher.com/python/os-module')
106 | print(Fore.WHITE + json.loads( data )['other']['os_exm'])
107 | print()
108 | print(Fore.YELLOW + '<---Example--->')
109 | print()
110 |
111 | # subprocess
112 | def subprocess_dec():
113 | print()
114 | print(Fore.YELLOW + '<---Description--->')
115 | print(Fore.WHITE + json.loads( data )['other']['subprocess_dec'])
116 | print()
117 | print(Fore.YELLOW + '<---Description--->')
118 | print()
119 |
120 | def subprocess_exm():
121 | print()
122 | print(Fore.YELLOW + '<---Example--->')
123 | print(Fore.CYAN + 'More Details : https://queirozf.com/entries/python-3-subprocess-examples')
124 | print(Fore.WHITE + json.loads( data )['other']['subprocess_exm'])
125 | print()
126 | print(Fore.YELLOW + '<---Example--->')
127 | print()
128 |
129 | # UrllibRequest
130 | def UrllibRequest_dec():
131 | print()
132 | print(Fore.YELLOW + '<---Description--->')
133 | print(Fore.WHITE + json.loads( data )['other']['urllib_request_dec'])
134 | print()
135 | print(Fore.YELLOW + '<---Description--->')
136 | print()
137 |
138 | def UrllibRequest_exm():
139 | print()
140 | print(Fore.YELLOW + '<---Example--->')
141 | print(Fore.CYAN + 'More Details : https://docs.python.org/3/library/urllib.request.html#examples')
142 | print(Fore.WHITE + json.loads( data )['other']['urllib_request_exm'])
143 | print()
144 | print(Fore.YELLOW + '<---Example--->')
145 | print()
146 |
147 |
148 | # Tkinter
149 | def Tkinter_dec():
150 | print()
151 | print(Fore.YELLOW + '<---Description--->')
152 | print(Fore.WHITE + json.loads( data )['other']['tkinter_dec'])
153 | print()
154 | print(Fore.YELLOW + '<---Description--->')
155 | print()
156 |
157 | def Tkinter_exm():
158 | print()
159 | print(Fore.YELLOW + '<---Example--->')
160 | print(Fore.CYAN + 'More Details : https://docs.python.org/3/library/tkinter.html#a-simple-hello-world-program')
161 | print(Fore.WHITE + json.loads( data )['other']['tkinter_exm'])
162 | print()
163 | print(Fore.YELLOW + '<---Example--->')
164 | print()
165 |
166 |
167 | # PyQt
168 | def PyQt5_installtion():
169 | print ('')
170 | print(Fore.YELLOW + '<---Installation--->')
171 | print(Fore.LIGHTGREEN_EX + 'PyQt5 :')
172 | print(Fore.WHITE + 'pip install PyQt5')
173 | print()
174 | print(Fore.LIGHTGREEN_EX + 'PyQt6 :')
175 | print(Fore.WHITE + 'pip install PyQt6')
176 | print(Fore.YELLOW + '<---Installation--->')
177 | print()
178 |
179 | def PyQt5_dec():
180 | print()
181 | print(Fore.YELLOW + '<---Description--->')
182 | print(Fore.WHITE + json.loads( data )['other']['pyqt_dec'])
183 | print(Fore.LIGHTRED_EX + 'PyQt4 and Qt v4 are no longer supported and no new releases will be made.')
184 | print()
185 | print(Fore.YELLOW + '<---Description--->')
186 | print()
187 |
188 | def PyQt5_exm():
189 | print()
190 | print(Fore.YELLOW + '<---Example--->')
191 | print(Fore.CYAN + 'More Details : https://www.riverbankcomputing.com/static/Docs/PyQt5/')
192 | print(Fore.WHITE + json.loads( data )['other']['pyqt_exm'])
193 | print()
194 | print(Fore.YELLOW + '<---Example--->')
195 | print()
196 |
197 |
198 | # datetime
199 | def datetime_dec():
200 | print()
201 | print(Fore.YELLOW + '<---Description--->')
202 | print(Fore.WHITE + json.loads( data )['other']['datetime_dec'])
203 | print()
204 | print(Fore.YELLOW + '<---Description--->')
205 | print()
206 |
207 | def datetime_exm():
208 | print()
209 | print(Fore.YELLOW + '<---Example--->')
210 | print(Fore.CYAN + 'More Details : https://docs.python.org/3/library/datetime.html#examples-of-usage-timedelta')
211 | print(Fore.WHITE + json.loads( data )['other']['datetime_exm'])
212 | print()
213 | print(Fore.YELLOW + '<---Example--->')
214 | print()
215 |
216 | # Json
217 | def JSON_dec():
218 | print()
219 | print(Fore.YELLOW + '<---Description--->')
220 | print(Fore.WHITE + json.loads( data )['other']['json_dec'])
221 | print()
222 | print(Fore.YELLOW + '<---Description--->')
223 | print()
224 |
225 | def JSON_exm():
226 | print()
227 | print(Fore.YELLOW + '<---Example--->')
228 | print(Fore.CYAN + 'More Details : https://docs.python.org/3/library/json.html#basic-usage')
229 | print(Fore.WHITE + json.loads( data )['other']['json_exm'])
230 | print()
231 | print(Fore.YELLOW + '<---Example--->')
232 | print()
233 |
234 | # Sys
235 | def Sys_dec():
236 | print()
237 | print(Fore.YELLOW + '<---Description--->')
238 | print(Fore.WHITE + json.loads( data )['other']['sys_dec'])
239 | print()
240 | print(Fore.YELLOW + '<---Description--->')
241 | print()
242 |
243 | def Sys_exm():
244 | print()
245 | print(Fore.YELLOW + '<---Example--->')
246 | print(Fore.CYAN + 'More Details : https://docs.python.org/3/library/sysconfig.html')
247 | print(Fore.WHITE + json.loads( data )['other']['sys_exm'])
248 | print()
249 | print(Fore.YELLOW + '<---Example--->')
250 | print()
251 |
252 |
253 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | GNU GENERAL PUBLIC LICENSE
2 | Version 2, June 1991
3 |
4 | Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
5 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
6 | Everyone is permitted to copy and distribute verbatim copies
7 | of this license document, but changing it is not allowed.
8 |
9 | Preamble
10 |
11 | The licenses for most software are designed to take away your
12 | freedom to share and change it. By contrast, the GNU General Public
13 | License is intended to guarantee your freedom to share and change free
14 | software--to make sure the software is free for all its users. This
15 | General Public License applies to most of the Free Software
16 | Foundation's software and to any other program whose authors commit to
17 | using it. (Some other Free Software Foundation software is covered by
18 | the GNU Lesser General Public License instead.) You can apply it to
19 | your programs, too.
20 |
21 | When we speak of free software, we are referring to freedom, not
22 | price. Our General Public Licenses are designed to make sure that you
23 | have the freedom to distribute copies of free software (and charge for
24 | this service if you wish), that you receive source code or can get it
25 | if you want it, that you can change the software or use pieces of it
26 | in new free programs; and that you know you can do these things.
27 |
28 | To protect your rights, we need to make restrictions that forbid
29 | anyone to deny you these rights or to ask you to surrender the rights.
30 | These restrictions translate to certain responsibilities for you if you
31 | distribute copies of the software, or if you modify it.
32 |
33 | For example, if you distribute copies of such a program, whether
34 | gratis or for a fee, you must give the recipients all the rights that
35 | you have. You must make sure that they, too, receive or can get the
36 | source code. And you must show them these terms so they know their
37 | rights.
38 |
39 | We protect your rights with two steps: (1) copyright the software, and
40 | (2) offer you this license which gives you legal permission to copy,
41 | distribute and/or modify the software.
42 |
43 | Also, for each author's protection and ours, we want to make certain
44 | that everyone understands that there is no warranty for this free
45 | software. If the software is modified by someone else and passed on, we
46 | want its recipients to know that what they have is not the original, so
47 | that any problems introduced by others will not reflect on the original
48 | authors' reputations.
49 |
50 | Finally, any free program is threatened constantly by software
51 | patents. We wish to avoid the danger that redistributors of a free
52 | program will individually obtain patent licenses, in effect making the
53 | program proprietary. To prevent this, we have made it clear that any
54 | patent must be licensed for everyone's free use or not licensed at all.
55 |
56 | The precise terms and conditions for copying, distribution and
57 | modification follow.
58 |
59 | GNU GENERAL PUBLIC LICENSE
60 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
61 |
62 | 0. This License applies to any program or other work which contains
63 | a notice placed by the copyright holder saying it may be distributed
64 | under the terms of this General Public License. The "Program", below,
65 | refers to any such program or work, and a "work based on the Program"
66 | means either the Program or any derivative work under copyright law:
67 | that is to say, a work containing the Program or a portion of it,
68 | either verbatim or with modifications and/or translated into another
69 | language. (Hereinafter, translation is included without limitation in
70 | the term "modification".) Each licensee is addressed as "you".
71 |
72 | Activities other than copying, distribution and modification are not
73 | covered by this License; they are outside its scope. The act of
74 | running the Program is not restricted, and the output from the Program
75 | is covered only if its contents constitute a work based on the
76 | Program (independent of having been made by running the Program).
77 | Whether that is true depends on what the Program does.
78 |
79 | 1. You may copy and distribute verbatim copies of the Program's
80 | source code as you receive it, in any medium, provided that you
81 | conspicuously and appropriately publish on each copy an appropriate
82 | copyright notice and disclaimer of warranty; keep intact all the
83 | notices that refer to this License and to the absence of any warranty;
84 | and give any other recipients of the Program a copy of this License
85 | along with the Program.
86 |
87 | You may charge a fee for the physical act of transferring a copy, and
88 | you may at your option offer warranty protection in exchange for a fee.
89 |
90 | 2. You may modify your copy or copies of the Program or any portion
91 | of it, thus forming a work based on the Program, and copy and
92 | distribute such modifications or work under the terms of Section 1
93 | above, provided that you also meet all of these conditions:
94 |
95 | a) You must cause the modified files to carry prominent notices
96 | stating that you changed the files and the date of any change.
97 |
98 | b) You must cause any work that you distribute or publish, that in
99 | whole or in part contains or is derived from the Program or any
100 | part thereof, to be licensed as a whole at no charge to all third
101 | parties under the terms of this License.
102 |
103 | c) If the modified program normally reads commands interactively
104 | when run, you must cause it, when started running for such
105 | interactive use in the most ordinary way, to print or display an
106 | announcement including an appropriate copyright notice and a
107 | notice that there is no warranty (or else, saying that you provide
108 | a warranty) and that users may redistribute the program under
109 | these conditions, and telling the user how to view a copy of this
110 | License. (Exception: if the Program itself is interactive but
111 | does not normally print such an announcement, your work based on
112 | the Program is not required to print an announcement.)
113 |
114 | These requirements apply to the modified work as a whole. If
115 | identifiable sections of that work are not derived from the Program,
116 | and can be reasonably considered independent and separate works in
117 | themselves, then this License, and its terms, do not apply to those
118 | sections when you distribute them as separate works. But when you
119 | distribute the same sections as part of a whole which is a work based
120 | on the Program, the distribution of the whole must be on the terms of
121 | this License, whose permissions for other licensees extend to the
122 | entire whole, and thus to each and every part regardless of who wrote it.
123 |
124 | Thus, it is not the intent of this section to claim rights or contest
125 | your rights to work written entirely by you; rather, the intent is to
126 | exercise the right to control the distribution of derivative or
127 | collective works based on the Program.
128 |
129 | In addition, mere aggregation of another work not based on the Program
130 | with the Program (or with a work based on the Program) on a volume of
131 | a storage or distribution medium does not bring the other work under
132 | the scope of this License.
133 |
134 | 3. You may copy and distribute the Program (or a work based on it,
135 | under Section 2) in object code or executable form under the terms of
136 | Sections 1 and 2 above provided that you also do one of the following:
137 |
138 | a) Accompany it with the complete corresponding machine-readable
139 | source code, which must be distributed under the terms of Sections
140 | 1 and 2 above on a medium customarily used for software interchange; or,
141 |
142 | b) Accompany it with a written offer, valid for at least three
143 | years, to give any third party, for a charge no more than your
144 | cost of physically performing source distribution, a complete
145 | machine-readable copy of the corresponding source code, to be
146 | distributed under the terms of Sections 1 and 2 above on a medium
147 | customarily used for software interchange; or,
148 |
149 | c) Accompany it with the information you received as to the offer
150 | to distribute corresponding source code. (This alternative is
151 | allowed only for noncommercial distribution and only if you
152 | received the program in object code or executable form with such
153 | an offer, in accord with Subsection b above.)
154 |
155 | The source code for a work means the preferred form of the work for
156 | making modifications to it. For an executable work, complete source
157 | code means all the source code for all modules it contains, plus any
158 | associated interface definition files, plus the scripts used to
159 | control compilation and installation of the executable. However, as a
160 | special exception, the source code distributed need not include
161 | anything that is normally distributed (in either source or binary
162 | form) with the major components (compiler, kernel, and so on) of the
163 | operating system on which the executable runs, unless that component
164 | itself accompanies the executable.
165 |
166 | If distribution of executable or object code is made by offering
167 | access to copy from a designated place, then offering equivalent
168 | access to copy the source code from the same place counts as
169 | distribution of the source code, even though third parties are not
170 | compelled to copy the source along with the object code.
171 |
172 | 4. You may not copy, modify, sublicense, or distribute the Program
173 | except as expressly provided under this License. Any attempt
174 | otherwise to copy, modify, sublicense or distribute the Program is
175 | void, and will automatically terminate your rights under this License.
176 | However, parties who have received copies, or rights, from you under
177 | this License will not have their licenses terminated so long as such
178 | parties remain in full compliance.
179 |
180 | 5. You are not required to accept this License, since you have not
181 | signed it. However, nothing else grants you permission to modify or
182 | distribute the Program or its derivative works. These actions are
183 | prohibited by law if you do not accept this License. Therefore, by
184 | modifying or distributing the Program (or any work based on the
185 | Program), you indicate your acceptance of this License to do so, and
186 | all its terms and conditions for copying, distributing or modifying
187 | the Program or works based on it.
188 |
189 | 6. Each time you redistribute the Program (or any work based on the
190 | Program), the recipient automatically receives a license from the
191 | original licensor to copy, distribute or modify the Program subject to
192 | these terms and conditions. You may not impose any further
193 | restrictions on the recipients' exercise of the rights granted herein.
194 | You are not responsible for enforcing compliance by third parties to
195 | this License.
196 |
197 | 7. If, as a consequence of a court judgment or allegation of patent
198 | infringement or for any other reason (not limited to patent issues),
199 | conditions are imposed on you (whether by court order, agreement or
200 | otherwise) that contradict the conditions of this License, they do not
201 | excuse you from the conditions of this License. If you cannot
202 | distribute so as to satisfy simultaneously your obligations under this
203 | License and any other pertinent obligations, then as a consequence you
204 | may not distribute the Program at all. For example, if a patent
205 | license would not permit royalty-free redistribution of the Program by
206 | all those who receive copies directly or indirectly through you, then
207 | the only way you could satisfy both it and this License would be to
208 | refrain entirely from distribution of the Program.
209 |
210 | If any portion of this section is held invalid or unenforceable under
211 | any particular circumstance, the balance of the section is intended to
212 | apply and the section as a whole is intended to apply in other
213 | circumstances.
214 |
215 | It is not the purpose of this section to induce you to infringe any
216 | patents or other property right claims or to contest validity of any
217 | such claims; this section has the sole purpose of protecting the
218 | integrity of the free software distribution system, which is
219 | implemented by public license practices. Many people have made
220 | generous contributions to the wide range of software distributed
221 | through that system in reliance on consistent application of that
222 | system; it is up to the author/donor to decide if he or she is willing
223 | to distribute software through any other system and a licensee cannot
224 | impose that choice.
225 |
226 | This section is intended to make thoroughly clear what is believed to
227 | be a consequence of the rest of this License.
228 |
229 | 8. If the distribution and/or use of the Program is restricted in
230 | certain countries either by patents or by copyrighted interfaces, the
231 | original copyright holder who places the Program under this License
232 | may add an explicit geographical distribution limitation excluding
233 | those countries, so that distribution is permitted only in or among
234 | countries not thus excluded. In such case, this License incorporates
235 | the limitation as if written in the body of this License.
236 |
237 | 9. The Free Software Foundation may publish revised and/or new versions
238 | of the General Public License from time to time. Such new versions will
239 | be similar in spirit to the present version, but may differ in detail to
240 | address new problems or concerns.
241 |
242 | Each version is given a distinguishing version number. If the Program
243 | specifies a version number of this License which applies to it and "any
244 | later version", you have the option of following the terms and conditions
245 | either of that version or of any later version published by the Free
246 | Software Foundation. If the Program does not specify a version number of
247 | this License, you may choose any version ever published by the Free Software
248 | Foundation.
249 |
250 | 10. If you wish to incorporate parts of the Program into other free
251 | programs whose distribution conditions are different, write to the author
252 | to ask for permission. For software which is copyrighted by the Free
253 | Software Foundation, write to the Free Software Foundation; we sometimes
254 | make exceptions for this. Our decision will be guided by the two goals
255 | of preserving the free status of all derivatives of our free software and
256 | of promoting the sharing and reuse of software generally.
257 |
258 | NO WARRANTY
259 |
260 | 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
261 | FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
262 | OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
263 | PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
264 | OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
265 | MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
266 | TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
267 | PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
268 | REPAIR OR CORRECTION.
269 |
270 | 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
271 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
272 | REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
273 | INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
274 | OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
275 | TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
276 | YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
277 | PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
278 | POSSIBILITY OF SUCH DAMAGES.
279 |
280 | END OF TERMS AND CONDITIONS
281 |
282 | How to Apply These Terms to Your New Programs
283 |
284 | If you develop a new program, and you want it to be of the greatest
285 | possible use to the public, the best way to achieve this is to make it
286 | free software which everyone can redistribute and change under these terms.
287 |
288 | To do so, attach the following notices to the program. It is safest
289 | to attach them to the start of each source file to most effectively
290 | convey the exclusion of warranty; and each file should have at least
291 | the "copyright" line and a pointer to where the full notice is found.
292 |
293 |
294 | Copyright (C)
295 |
296 | This program is free software; you can redistribute it and/or modify
297 | it under the terms of the GNU General Public License as published by
298 | the Free Software Foundation; either version 2 of the License, or
299 | (at your option) any later version.
300 |
301 | This program is distributed in the hope that it will be useful,
302 | but WITHOUT ANY WARRANTY; without even the implied warranty of
303 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
304 | GNU General Public License for more details.
305 |
306 | You should have received a copy of the GNU General Public License along
307 | with this program; if not, write to the Free Software Foundation, Inc.,
308 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
309 |
310 | Also add information on how to contact you by electronic and paper mail.
311 |
312 | If the program is interactive, make it output a short notice like this
313 | when it starts in an interactive mode:
314 |
315 | Gnomovision version 69, Copyright (C) year name of author
316 | Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
317 | This is free software, and you are welcome to redistribute it
318 | under certain conditions; type `show c' for details.
319 |
320 | The hypothetical commands `show w' and `show c' should show the appropriate
321 | parts of the General Public License. Of course, the commands you use may
322 | be called something other than `show w' and `show c'; they could even be
323 | mouse-clicks or menu items--whatever suits your program.
324 |
325 | You should also get your employer (if you work as a programmer) or your
326 | school, if any, to sign a "copyright disclaimer" for the program, if
327 | necessary. Here is a sample; alter the names:
328 |
329 | Yoyodyne, Inc., hereby disclaims all copyright interest in the program
330 | `Gnomovision' (which makes passes at compilers) written by James Hacker.
331 |
332 | , 1 April 1989
333 | Ty Coon, President of Vice
334 |
335 | This General Public License does not permit incorporating your program into
336 | proprietary programs. If your program is a subroutine library, you may
337 | consider it more useful to permit linking proprietary applications with the
338 | library. If this is what you want to do, use the GNU Lesser General
339 | Public License instead of this License.
340 |
--------------------------------------------------------------------------------
/imports/Courses.py:
--------------------------------------------------------------------------------
1 | # <------CoDed By AnonCODER------>
2 | # <------v3.0----->
3 | # <------Now PyLe needs your support with its release------>
4 | # <------PyLe in Github : https://github.com/AnonC0DER/PyLe------>
5 | ##################################################################
6 |
7 | # imports
8 | import random
9 | import urllib.request
10 | from colorama import Fore
11 | from time import sleep
12 | from os import system
13 | # Close time
14 | import time
15 | from datetime import datetime
16 |
17 | #colors class
18 | class colors:
19 | MAGENTA = Fore.LIGHTMAGENTA_EX
20 | YELLOW = Fore.LIGHTYELLOW_EX
21 | BLUE = Fore.LIGHTBLUE_EX
22 | RED = Fore.LIGHTRED_EX
23 | CYAN = Fore.LIGHTCYAN_EX
24 | WHITE = Fore.LIGHTWHITE_EX
25 |
26 |
27 | random_color = [colors.MAGENTA,colors.YELLOW,colors.RED,colors.BLUE,colors.CYAN,colors.WHITE]
28 | random.shuffle(random_color)
29 |
30 | # FreeCourses
31 | def FreeCourses():
32 | '''
33 | FreeCourses function
34 | English and Persian YouTube FreeCourses
35 | If You Wanna Copy this videos in your projects, Please put their YouTube Accounts in Your Project
36 | Good Luck everyone :)
37 | '''
38 | system('clear')
39 | print(random_color [0] + '''
40 | ███████ ██████ ███████ ███████ ██████ ██████ ██ ██ ██████ ███████ ███████ ███████
41 | ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
42 | █████ ██████ █████ █████ ██ ██ ██ ██ ██ ██████ ███████ █████ ███████
43 | ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
44 | ██ ██ ██ ███████ ███████ ██████ ██████ ██████ ██ ██ ███████ ███████ ███████
45 | ''')
46 |
47 | print(Fore.LIGHTGREEN_EX + '[+]' + Fore.LIGHTMAGENTA_EX + ' You can see Download and see Free YouTube Courses.')
48 | print(Fore.LIGHTRED_EX + '[~] Pay Attention' + Fore.LIGHTCYAN_EX+ ' To support free tutoring teachers, subscribe to their YouTube account.')
49 | print(Fore.LIGHTWHITE_EX + '[*]' + Fore.LIGHTYELLOW_EX + ' First choose your language for Courses (-Persian (P), English(E), Exit(exit)-)')
50 | print()
51 |
52 | courses = input(Fore.LIGHTYELLOW_EX + 'PyLe ~$ ')
53 | if courses.upper() == 'P':
54 | print(Fore.LIGHTMAGENTA_EX + '''
55 | 1 = Make A Simple Python Keylogger
56 | 2 = WhatsApp Bot With Python
57 | 3 = Write a simple RAT with Python
58 | 4 = Complete tutorial on making a floppy bird game with Pygame
59 | 5 = The best programming tools, install Python on Linux and Windows
60 | 6 = Learn how to convert a Python program to an exe file
61 | 7 = Random Number in Python
62 | 8 = Get a WiFi password with Python
63 | 9 = Python Tutorial
64 |
65 | 100 => FreeCourses Menu
66 | ''')
67 | persian_courses = int(input(Fore.LIGHTYELLOW_EX + 'PyLe ~$ '))
68 | # Make A Simple Python Keylogger
69 | if persian_courses == 1:
70 | system('clear')
71 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can learn how to make a useful Keylogger with python.')
72 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : Qadir Yolme | Size : 273Mb')
73 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
74 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://youtube.com/channel/UCO8iviFPYxykxTG1M7XdMKw")
75 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/XUkRU5zE04w')
76 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/per/qadir_yolme_Keylogger.mp4')
77 | print(Fore.LIGHTCYAN_EX + '------------------------------')
78 | # Download the Video
79 | download_Keylogger = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
80 |
81 | if download_Keylogger.upper() == 'Y':
82 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
83 | try :
84 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/per/qadir_yolme_Keylogger.mp4', 'qadir_yolme_Keylogger.mp4')
85 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
86 | sleep(0.5)
87 | FreeCourses()
88 | # if there is any problems like, No internet connection or server problems :
89 | except :
90 | print(Fore.LIGHTRED_EX + '''
91 | Something Went Wrong !
92 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
93 | ''')
94 | sleep(1.7)
95 | FreeCourses()
96 |
97 | elif download_Keylogger.upper() == 'N':
98 | sleep(0.5)
99 | FreeCourses()
100 |
101 | else:
102 | print(Fore.RED + '[!] Wrong Value')
103 | sleep(1.0)
104 | FreeCourses()
105 |
106 | # WhatsApp Bot With Python
107 | elif persian_courses == 2:
108 | system('clear')
109 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can learn how to make a WhatsApp Bot With Python.')
110 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : AmirHossein Moalemi | Size : Part1 = 62Mb / Part2 = 58Mb')
111 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
112 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://youtube.com/c/Nabegheha")
113 | print(Fore.LIGHTWHITE_EX + 'Video Links (2 Part) => p1 = (https://youtu.be/VLxnPdJS1HE) / p2 = (https://youtu.be/hgwTZfw7ciY)')
114 | print(Fore.LIGHTBLUE_EX + 'Direct download link (part 1) : https://dl.pyle-pythonlearning.ir/videos/per/01.WhatsApp_Bot_Using_Python.mp4')
115 | print(Fore.LIGHTBLUE_EX + 'Direct download link (part 2) : https://dl.pyle-pythonlearning.ir/videos/per/02.WhatsApp_Bot_Using_Python.mp4')
116 | print(Fore.LIGHTCYAN_EX + '------------------------------')
117 | # Download the Video
118 | WhatsApp_Bot = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
119 |
120 | if WhatsApp_Bot.upper() == 'Y':
121 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading... (2 Parts)')
122 | try :
123 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/per/01.WhatsApp_Bot_Using_Python.mp4', '01.WhatsApp_Bot_Using_Python.mp4')
124 | print(Fore.LIGHTGREEN_EX + 'Part 1 Downloaded. Downloading... (Part 2)')
125 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/per/02.WhatsApp_Bot_Using_Python.mp4', '02.WhatsApp_Bot_Using_Python.mp4')
126 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
127 | sleep(0.5)
128 | FreeCourses()
129 | # if there is any problems like, No internet connection or server problems :
130 | except :
131 | print(Fore.LIGHTRED_EX + '''
132 | Something Went Wrong !
133 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
134 | ''')
135 | sleep(1.7)
136 | FreeCourses()
137 |
138 | elif WhatsApp_Bot.upper() == 'N':
139 | sleep(0.5)
140 | FreeCourses()
141 |
142 | else:
143 | print(Fore.RED + '[!] Wrong Value')
144 | sleep(1.0)
145 | FreeCourses()
146 |
147 | # Write a simple RAT with Python
148 | elif persian_courses == 3:
149 | system('clear')
150 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can learn how to Write a simple RAT with Python.')
151 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : Qadir Yolme | Size : 126Mb')
152 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
153 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://youtube.com/channel/UCO8iviFPYxykxTG1M7XdMKw")
154 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/H55t7Fa-ftQ')
155 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/per/Write_a_simple_RAT_with_Python.mp4')
156 | print(Fore.LIGHTCYAN_EX + '------------------------------')
157 | # Download the Video
158 | RAT_with_Python = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
159 |
160 | if RAT_with_Python.upper() == 'Y':
161 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
162 | try:
163 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/per/Write_a_simple_RAT_with_Python.mp4', 'Write_a_simple_RAT_with_Python.mp4')
164 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
165 | sleep(0.5)
166 | FreeCourses()
167 | # if there is any problems like, No internet connection or server problems :
168 | except :
169 | print(Fore.LIGHTRED_EX + '''
170 | Something Went Wrong !
171 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
172 | ''')
173 | sleep(1.7)
174 | FreeCourses()
175 |
176 | elif RAT_with_Python.upper() == 'N':
177 | sleep(0.5)
178 | FreeCourses()
179 |
180 | else:
181 | print(Fore.RED + '[!] Wrong Value')
182 | sleep(1.0)
183 | FreeCourses()
184 |
185 | # Complete tutorial on making a floppy bird game with Pygame
186 | elif persian_courses == 4:
187 | system('clear')
188 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can learn how to make a floppy bird game with Pygame.')
189 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : AmirHossein Moalemi | Size : 324Mb')
190 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
191 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://youtube.com/c/Nabegheha")
192 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/feFDkcUHA9Y')
193 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/per/Pygame_Tutorial_floppy_bird.mp4')
194 | print(Fore.LIGHTCYAN_EX + '------------------------------')
195 | # Download the Video
196 | floppy_bird = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
197 |
198 | if floppy_bird.upper() == 'Y':
199 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
200 | try:
201 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/per/Pygame_Tutorial_floppy_bird.mp4', 'Pygame_Tutorial_floppy_bird.mp4')
202 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
203 | sleep(0.5)
204 | FreeCourses()
205 | # if there is any problems like, No internet connection or server problems :
206 | except :
207 | print(Fore.LIGHTRED_EX + '''
208 | Something Went Wrong !
209 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
210 | ''')
211 | sleep(1.7)
212 | FreeCourses()
213 |
214 | elif floppy_bird.upper() == 'N':
215 | sleep(0.5)
216 | FreeCourses()
217 |
218 | else:
219 | print(Fore.RED + '[!] Wrong Value')
220 | sleep(1.0)
221 | FreeCourses()
222 |
223 | # The best programming tools, install Python on Linux and Windows
224 | elif persian_courses == 5:
225 | system('clear')
226 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can learn how to install Python on Linux and Windows and know about the best programming tools.')
227 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : AmirHossein Moalemi | Size : 68Mb')
228 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
229 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://youtube.com/c/Nabegheha")
230 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/HYr2ic1_5tA')
231 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/per/best_programming_tools.mp4')
232 | print(Fore.LIGHTCYAN_EX + '------------------------------')
233 | # Download the Video
234 | programming_tools = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
235 |
236 | if programming_tools.upper() == 'Y':
237 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
238 | try:
239 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/per/best_programming_tools.mp4', 'best_programming_tools.mp4')
240 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
241 | sleep(0.5)
242 | FreeCourses()
243 | # if there is any problems like, No internet connection or server problems :
244 | except :
245 | print(Fore.LIGHTRED_EX + '''
246 | Something Went Wrong !
247 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
248 | ''')
249 | sleep(1.7)
250 | FreeCourses()
251 |
252 | elif programming_tools.upper() == 'N':
253 | sleep(0.5)
254 | FreeCourses()
255 |
256 | else:
257 | print(Fore.RED + '[!] Wrong Value')
258 | sleep(1.0)
259 | FreeCourses()
260 |
261 | # Learn how to convert a Python program to an exe file
262 | elif persian_courses == 6:
263 | system('clear')
264 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can learn how to convert a Python program to an exe file.')
265 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : AmirHossein Moalemi | Size : 44Mb')
266 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
267 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://youtube.com/c/Nabegheha")
268 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/CkiwlO8kVRI')
269 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/per/convert_a_Python_program_to_an_exe_file.mp4')
270 | print(Fore.LIGHTCYAN_EX + '------------------------------')
271 | # Download the Video
272 | convert_Python = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
273 |
274 | if convert_Python.upper() == 'Y':
275 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
276 | try:
277 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/per/convert_a_Python_program_to_an_exe_file.mp4', 'convert_a_Python_program_to_an_exe_file.mp4')
278 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
279 | sleep(0.5)
280 | FreeCourses()
281 | # if there is any problems like, No internet connection or server problems :
282 | except :
283 | print(Fore.LIGHTRED_EX + '''
284 | Something Went Wrong !
285 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
286 | ''')
287 | sleep(1.7)
288 | FreeCourses()
289 |
290 | elif convert_Python.upper() == 'N':
291 | sleep(0.5)
292 | FreeCourses()
293 |
294 | else:
295 | print(Fore.RED + '[!] Wrong Value')
296 | sleep(1.0)
297 | FreeCourses()
298 |
299 | # Random Number in Python
300 | elif persian_courses == 7:
301 | system('clear')
302 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can learn how to make Random Numbers in Python.')
303 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : AmirHossein Moalemi | Size : 28Mb')
304 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
305 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://youtube.com/c/Nabegheha")
306 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/5O4fSbrKAKA')
307 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/per/Random_Number_in_Python.mp4')
308 | print(Fore.LIGHTCYAN_EX + '------------------------------')
309 | # Download the Video
310 | Random_Number = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
311 |
312 | if Random_Number.upper() == 'Y':
313 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
314 | try:
315 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/per/Random_Number_in_Python.mp4', 'Random_Number_in_Python.mp4')
316 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
317 | sleep(0.5)
318 | FreeCourses()
319 | # if there is any problems like, No internet connection or server problems :
320 | except :
321 | print(Fore.LIGHTRED_EX + '''
322 | Something Went Wrong !
323 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
324 | ''')
325 | sleep(1.7)
326 | FreeCourses()
327 |
328 | elif Random_Number.upper() == 'N':
329 | sleep(0.5)
330 | FreeCourses()
331 |
332 | else:
333 | print(Fore.RED + '[!] Wrong Value')
334 | sleep(1.0)
335 | FreeCourses()
336 |
337 | # Get a WiFi password with Python
338 | elif persian_courses == 8:
339 | system('clear')
340 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can learn how to make Random Numbers in Python.')
341 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : Qadir Yolme | Size : 51Mb')
342 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
343 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://youtube.com/channel/UCO8iviFPYxykxTG1M7XdMKw")
344 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/5ArbYwhV60Y')
345 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/per/Get_a_WiFi_password_with_Python.mp4')
346 | print(Fore.LIGHTCYAN_EX + '------------------------------')
347 | # Download the Video
348 | WiFi_password = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
349 |
350 | if WiFi_password.upper() == 'Y':
351 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
352 | try:
353 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/per/Get_a_WiFi_password_with_Python.mp4', 'Get_a_WiFi_password_with_Python.mp4')
354 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
355 | sleep(0.5)
356 | FreeCourses()
357 | # if there is any problems like, No internet connection or server problems :
358 | except :
359 | print(Fore.LIGHTRED_EX + '''
360 | Something Went Wrong !
361 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
362 | ''')
363 | sleep(1.7)
364 | FreeCourses()
365 |
366 | elif WiFi_password.upper() == 'N':
367 | sleep(0.5)
368 | FreeCourses()
369 |
370 | else:
371 | print(Fore.RED + '[!] Wrong Value')
372 | sleep(1.0)
373 | FreeCourses()
374 |
375 | # Python Tutorial
376 | elif persian_courses == 9:
377 | system('clear')
378 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you will learn basic python.')
379 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : Vision Academy | Size : 261Mb')
380 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
381 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://youtube.com/channel/UCdJNIDb8lDrdRzPNbD7yTkQ")
382 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/hSt3_2T6DMU')
383 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/per/Python_Tutorial_Farsi.mkv')
384 | print(Fore.LIGHTCYAN_EX + '------------------------------')
385 | # Download the Video
386 | WiFi_password = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
387 |
388 | if WiFi_password.upper() == 'Y':
389 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
390 | try:
391 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/per/Python_Tutorial_Farsi.mkv', 'Python_Tutorial_Farsi.mkv')
392 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
393 | sleep(0.5)
394 | FreeCourses()
395 | # if there is any problems like, No internet connection or server problems :
396 | except :
397 | print(Fore.LIGHTRED_EX + '''
398 | Something Went Wrong !
399 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
400 | ''')
401 | sleep(1.7)
402 | FreeCourses()
403 |
404 | elif WiFi_password.upper() == 'N':
405 | sleep(0.5)
406 | FreeCourses()
407 |
408 | else:
409 | print(Fore.RED + '[!] Wrong Value')
410 | sleep(1.0)
411 | FreeCourses()
412 |
413 | # FreeCourses Menu
414 | elif persian_courses == 100:
415 | FreeCourses()
416 |
417 | else:
418 | print(Fore.RED + '[!] Wrong Value')
419 | sleep(1.0)
420 | FreeCourses()
421 |
422 |
423 | elif courses.upper() == 'E':
424 | print(Fore.LIGHTGREEN_EX + '''
425 | 1 = Python NumPy Tutorial for Beginners
426 | 2 = Scikit Learn Course Machine Learning in Python Tutorial
427 | 3 = Keras with TensorFlow Course Python Deep Learning
428 | 4 = Coding Telegram Bot using Python
429 | 5 = How To Create A Telegram Bot With Python
430 | 6 = Complete Python Turtle Graphics Overview
431 | 7 = Python Game Development Course
432 | 8 = Step-by-Step Python and Postgres Tutorial with psycopg2
433 | 9 = Matplotlib Crash Course
434 | 10 = Learn Python - Full Course for Beginners
435 | 11 = Create a Notepad using Python
436 |
437 | 100 => FreeCourses Menu
438 | ''')
439 |
440 | english_courses = int(input(Fore.LIGHTYELLOW_EX + 'PyLe ~$ '))
441 | # Python NumPy Tutorial for Beginners
442 | if english_courses == 1:
443 | system('clear')
444 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can Learn the basics of the NumPy library in this tutorial for beginners.')
445 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : Keith Galli | Size : 85Mb')
446 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
447 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://www.youtube.com/channel/UCq6XkhO5SZ66N04IcPbqNcw")
448 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/QUT1VHiLmmI')
449 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/eng/Python_NumPy_Tutorial_for_Beginners.mp4')
450 | print(Fore.LIGHTCYAN_EX + '------------------------------')
451 | # Download the Video
452 | numpy_video = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
453 |
454 | if numpy_video.upper() == 'Y':
455 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
456 | try:
457 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/eng/Python_NumPy_Tutorial_for_Beginners.mp4', 'Python_NumPy_Tutorial_for_Beginners.mp4')
458 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
459 | sleep(0.5)
460 | FreeCourses()
461 | # if there is any problems like, No internet connection or server problems :
462 | except :
463 | print(Fore.LIGHTRED_EX + '''
464 | Something Went Wrong !
465 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
466 | ''')
467 | sleep(1.7)
468 | FreeCourses()
469 |
470 | elif numpy_video.upper() == 'N':
471 | sleep(0.5)
472 | FreeCourses()
473 |
474 | else:
475 | print(Fore.RED + '[!] Wrong Value')
476 | sleep(1.0)
477 | FreeCourses()
478 |
479 | # Scikit Learn Course Machine Learning in Python Tutorial
480 | elif english_courses == 2:
481 | system('clear')
482 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can Learn about machine learning using scikit-learn in this full course..')
483 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : freeCodeCamp | Size : 279Mb')
484 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
485 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://www.youtube.com/channel/UC8butISFwT-Wl7EV0hUK0BQ")
486 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/pqNCD_5r0IU')
487 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/eng/Scikit_Learn_Course_Machine_Learning_in_Python_Tutorial.mp4')
488 | print(Fore.LIGHTCYAN_EX + '------------------------------')
489 | # Download the Video
490 | Scikit_video = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
491 |
492 | if Scikit_video.upper() == 'Y':
493 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
494 | try:
495 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/eng/Scikit_Learn_Course_Machine_Learning_in_Python_Tutorial.mp4', 'Scikit_Learn_Course_Machine_Learning_in_Python_Tutorial.mp4')
496 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
497 | sleep(0.5)
498 | FreeCourses()
499 | # if there is any problems like, No internet connection or server problems :
500 | except :
501 | print(Fore.LIGHTRED_EX + '''
502 | Something Went Wrong !
503 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
504 | ''')
505 | sleep(1.7)
506 | FreeCourses()
507 |
508 | elif Scikit_video.upper() == 'N':
509 | sleep(0.5)
510 | FreeCourses()
511 |
512 | else:
513 | print(Fore.RED + '[!] Wrong Value')
514 | sleep(1.0)
515 | FreeCourses()
516 |
517 | # Keras with TensorFlow Course Python Deep Learning
518 | elif english_courses == 3:
519 | system('clear')
520 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can learn how to prepare and process data for artificial neural networks, build and train artificial neural networks from scratch, build and train convolutional neural networks.')
521 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : freeCodeCamp | Size : 266Mb')
522 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
523 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://www.youtube.com/channel/UC8butISFwT-Wl7EV0hUK0BQ")
524 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/qFJeN9V1ZsI')
525 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/eng/Keras_with_TensorFlow_Course_Python.mp4')
526 | print(Fore.LIGHTCYAN_EX + '------------------------------')
527 | # Download the Video
528 | Keras_video = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
529 |
530 | if Keras_video.upper() == 'Y':
531 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
532 | try:
533 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/eng/Keras_with_TensorFlow_Course_Python.mp4', 'Scikit_Learn_Course_Machine_Learning_in_Python_Tutorial.mp4')
534 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
535 | sleep(0.5)
536 | FreeCourses()
537 | # if there is any problems like, No internet connection or server problems :
538 | except :
539 | print(Fore.LIGHTRED_EX + '''
540 | Something Went Wrong !
541 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
542 | ''')
543 | sleep(1.7)
544 | FreeCourses()
545 |
546 | elif Keras_video.upper() == 'N':
547 | sleep(0.5)
548 | FreeCourses()
549 |
550 | else:
551 | print(Fore.RED + '[!] Wrong Value')
552 | sleep(1.0)
553 | FreeCourses()
554 |
555 | # Coding Telegram Bot using Python
556 | elif english_courses == 4:
557 | system('clear')
558 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can Learn Coding Telegram Bot using Python.')
559 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : Sumanjay | Size : 240Mb')
560 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
561 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://www.youtube.com/channel/UC_AlIxCSFvOnYw5k6HAKmjg")
562 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/wdiWGmg_IRM')
563 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/eng/Coding_Telegram_Bot_using_Python.mkv')
564 | print(Fore.LIGHTCYAN_EX + '------------------------------')
565 | # Download the Video
566 | TelegramBot_video = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
567 |
568 | if TelegramBot_video.upper() == 'Y':
569 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
570 | try:
571 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/eng/Coding_Telegram_Bot_using_Python.mkv', 'Coding_Telegram_Bot_using_Python.mkv')
572 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
573 | sleep(0.5)
574 | FreeCourses()
575 | # if there is any problems like, No internet connection or server problems :
576 | except :
577 | print(Fore.LIGHTRED_EX + '''
578 | Something Went Wrong !
579 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
580 | ''')
581 | sleep(1.7)
582 | FreeCourses()
583 |
584 | elif TelegramBot_video.upper() == 'N':
585 | sleep(0.5)
586 | FreeCourses()
587 |
588 | else:
589 | print(Fore.RED + '[!] Wrong Value')
590 | sleep(1.0)
591 | FreeCourses()
592 |
593 | # How To Create A Telegram Bot With Python
594 | elif english_courses == 5:
595 | system('clear')
596 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can Learn how to make a Telegram bot with Python.')
597 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : CS Dojo | Size : 93Mb')
598 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
599 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://www.youtube.com/channel/UCxX9wt5FWQUAAz4UrysqK9A")
600 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/NwBWW8cNCP4')
601 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/eng/How_To_Create_A_Telegram_Bot_With_Python.mp4')
602 | print(Fore.LIGHTCYAN_EX + '------------------------------')
603 | # Download the Video
604 | Create_A_TelegramBot_video = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
605 |
606 | if Create_A_TelegramBot_video.upper() == 'Y':
607 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
608 | try:
609 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/eng/How_To_Create_A_Telegram_Bot_With_Python.mp4', 'How_To_Create_A_Telegram_Bot_With_Python.mp4')
610 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
611 | sleep(0.5)
612 | FreeCourses()
613 | # if there is any problems like, No internet connection or server problems :
614 | except :
615 | print(Fore.LIGHTRED_EX + '''
616 | Something Went Wrong !
617 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
618 | ''')
619 | sleep(1.7)
620 | FreeCourses()
621 |
622 | elif Create_A_TelegramBot_video.upper() == 'N':
623 | sleep(0.5)
624 | FreeCourses()
625 |
626 | else:
627 | print(Fore.RED + '[!] Wrong Value')
628 | sleep(1.0)
629 | FreeCourses()
630 |
631 | # Complete Python Turtle Graphics Overview
632 | elif english_courses == 6:
633 | system('clear')
634 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, he walks through the Turtle Graphics library of Python.')
635 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : Keith Galli | Size : 98Mb')
636 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
637 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://www.youtube.com/channel/UCq6XkhO5SZ66N04IcPbqNcw")
638 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/pxKu2pQ7ILo')
639 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/eng/Complete_Python_Turtle.mp4')
640 | print(Fore.LIGHTCYAN_EX + '------------------------------')
641 | # Download the Video
642 | Turtle_video = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
643 |
644 | if Turtle_video.upper() == 'Y':
645 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
646 | try:
647 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/eng/Complete_Python_Turtle.mp4', 'Complete_Python_Turtle.mp4')
648 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
649 | sleep(0.5)
650 | FreeCourses()
651 | # if there is any problems like, No internet connection or server problems :
652 | except :
653 | print(Fore.LIGHTRED_EX + '''
654 | Something Went Wrong !
655 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
656 | ''')
657 | sleep(1.7)
658 | FreeCourses()
659 |
660 | elif Turtle_video.upper() == 'N':
661 | sleep(0.5)
662 | FreeCourses()
663 |
664 | else:
665 | print(Fore.RED + '[!] Wrong Value')
666 | sleep(1.0)
667 | FreeCourses()
668 |
669 | # Python Game Development Course
670 | elif english_courses == 7:
671 | system('clear')
672 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can Learn how to use Pygame to code games with Python.')
673 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : freeCodeCamp | Size : 218Mb')
674 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
675 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://www.youtube.com/channel/UC8butISFwT-Wl7EV0hUK0BQ")
676 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/FfWpgLFMI7w')
677 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/eng/Pygame_Tutorial_for_Beginners_Python.mp4')
678 | print(Fore.LIGHTCYAN_EX + '------------------------------')
679 | # Download the Video
680 | GameDevelopment_vide = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
681 |
682 | if GameDevelopment_vide.upper() == 'Y':
683 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
684 | try:
685 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/eng/Pygame_Tutorial_for_Beginners_Python.mp4', 'Pygame_Tutorial_for_Beginners_Python.mp4')
686 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
687 | sleep(0.5)
688 | FreeCourses()
689 | # if there is any problems like, No internet connection or server problems :
690 | except :
691 | print(Fore.LIGHTRED_EX + '''
692 | Something Went Wrong !
693 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
694 | ''')
695 | sleep(1.7)
696 | FreeCourses()
697 |
698 | elif GameDevelopment_vide.upper() == 'N':
699 | sleep(0.5)
700 | FreeCourses()
701 |
702 | else:
703 | print(Fore.RED + '[!] Wrong Value')
704 | sleep(1.0)
705 | FreeCourses()
706 |
707 | # Step-by-Step Python and Postgres Tutorial with psycopg2
708 | elif english_courses == 8:
709 | system('clear')
710 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you will go through the basic steps on how to write a python script to read and write data on a Postgres database.')
711 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : Hussein Nasser | Size : 38Mb')
712 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
713 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://www.youtube.com/channel/UC_ML5xP23TOWKUcc-oAE_Eg")
714 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/2PDkXviEMD0')
715 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/eng/Step_by_Step_Python_and_Postgres_Tutorial_with_psycopg2.mp4')
716 | print(Fore.LIGHTCYAN_EX + '------------------------------')
717 | # Download the Video
718 | StepByStep_video = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
719 |
720 | if StepByStep_video.upper() == 'Y':
721 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
722 | try:
723 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/eng/Step_by_Step_Python_and_Postgres_Tutorial_with_psycopg2.mp4', 'Step_by_Step_Python_and_Postgres_Tutorial_with_psycopg2.mp4')
724 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
725 | sleep(0.5)
726 | FreeCourses()
727 | # if there is any problems like, No internet connection or server problems :
728 | except :
729 | print(Fore.LIGHTRED_EX + '''
730 | Something Went Wrong !
731 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
732 | ''')
733 | sleep(1.7)
734 | FreeCourses()
735 |
736 | elif StepByStep_video.upper() == 'N':
737 | sleep(0.5)
738 | FreeCourses()
739 |
740 | else:
741 | print(Fore.RED + '[!] Wrong Value')
742 | sleep(1.0)
743 | FreeCourses()
744 |
745 | # Matplotlib Crash Course
746 | elif english_courses == 9:
747 | system('clear')
748 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'In this video, you can Learn the basics of Matplotlib in this crash course tutorial. Matplotlib is an amazing data visualization library for Python.')
749 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : freeCodeCamp | Size : 232Mb')
750 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
751 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://www.youtube.com/channel/UC8butISFwT-Wl7EV0hUK0BQ")
752 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/3Xc3CA655Y4')
753 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/eng/Matplotlib_Crash_Course.mp4')
754 | print(Fore.LIGHTCYAN_EX + '------------------------------')
755 | # Download the Video
756 | Matplotlib_video = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
757 |
758 | if Matplotlib_video.upper() == 'Y':
759 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
760 | try:
761 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/eng/Matplotlib_Crash_Course.mp4', 'Matplotlib_Crash_Course.mp4')
762 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
763 | sleep(0.5)
764 | FreeCourses()
765 | # if there is any problems like, No internet connection or server problems :
766 | except :
767 | print(Fore.LIGHTRED_EX + '''
768 | Something Went Wrong !
769 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
770 | ''')
771 | sleep(1.7)
772 | FreeCourses()
773 |
774 | elif Matplotlib_video.upper() == 'N':
775 | sleep(0.5)
776 | FreeCourses()
777 |
778 | else:
779 | print(Fore.RED + '[!] Wrong Value')
780 | sleep(1.0)
781 | FreeCourses()
782 |
783 | # Learn Python - Full Course for Beginners
784 | elif english_courses == 10:
785 | system('clear')
786 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'This course will give you a full introduction into all of the core concepts in python.')
787 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : Mike Dane | Size : 278Mb')
788 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
789 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://www.youtube.com/channel/UCvmINlrza7JHB1zkIOuXEbw")
790 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/rfscVS0vtbw')
791 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/eng/Learn_Python_Full_Course_for_Beginners_Tutorial.mp4')
792 | print(Fore.LIGHTCYAN_EX + '------------------------------')
793 | # Download the Video
794 | LearnPython_video = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
795 |
796 | if LearnPython_video.upper() == 'Y':
797 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
798 | try:
799 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/eng/Learn_Python_Full_Course_for_Beginners_Tutorial.mp4', 'Learn_Python_Full_Course_for_Beginners_Tutorial.mp4')
800 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
801 | sleep(0.5)
802 | FreeCourses()
803 | # if there is any problems like, No internet connection or server problems :
804 | except :
805 | print(Fore.LIGHTRED_EX + '''
806 | Something Went Wrong !
807 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
808 | ''')
809 | sleep(1.7)
810 | FreeCourses()
811 |
812 | elif LearnPython_video.upper() == 'N':
813 | sleep(0.5)
814 | FreeCourses()
815 |
816 | else:
817 | print(Fore.RED + '[!] Wrong Value')
818 | sleep(1.0)
819 | FreeCourses()
820 |
821 | # Create a NotePad using python
822 | elif english_courses == 11:
823 | system('clear')
824 | print(Fore.LIGHTGREEN_EX + '[@] ' + Fore.LIGHTCYAN_EX + 'This course will give you a full introduction into all of the core concepts in python.')
825 | print(Fore.LIGHTYELLOW_EX + '[#] ' + Fore.LIGHTMAGENTA_EX + 'Teacher / Academy : Mike Dane | Size : 44Mb')
826 | print(Fore.LIGHTRED_EX + "To support free tutoring teachers, See and subscribe teachers's YouTube account :")
827 | print(Fore.LIGHTWHITE_EX + "Teacher's / Academy's Youtube : Account = https://youtube.com/c/Iknowpython")
828 | print(Fore.LIGHTWHITE_EX + 'Video Link = https://youtu.be/qxJBXnH-F3M')
829 | print(Fore.LIGHTBLUE_EX + 'Direct download link : https://dl.pyle-pythonlearning.ir/videos/eng/How_to_create_Notepad_using_Python.mp4')
830 | print(Fore.LIGHTCYAN_EX + '------------------------------')
831 | # Download the Video
832 | LearnPython_video = input(Fore.LIGHTGREEN_EX + 'Do You Wanna Download the video? (Y / N) : ')
833 |
834 | if LearnPython_video.upper() == 'Y':
835 | print(Fore.LIGHTGREEN_EX + 'Please Wait, Downloading...')
836 | try:
837 | urllib.request.urlretrieve('https://dl.pyle-pythonlearning.ir/videos/eng/How_to_create_Notepad_using_Python.mp4', 'How_to_create_Notepad_using_Python.mp4')
838 | print(Fore.LIGHTMAGENTA_EX + 'Done !')
839 | sleep(0.5)
840 | FreeCourses()
841 | # if there is any problems like, No internet connection or server problems :
842 | except :
843 | print(Fore.LIGHTRED_EX + '''
844 | Something Went Wrong !
845 | Error Details : No internet connection, Server problems Or KeyboardInterrupt(Ctrl + C)
846 | ''')
847 | sleep(1.7)
848 | FreeCourses()
849 |
850 | elif LearnPython_video.upper() == 'N':
851 | sleep(0.5)
852 | FreeCourses()
853 |
854 | else:
855 | print(Fore.RED + '[!] Wrong Value')
856 | sleep(1.0)
857 | FreeCourses()
858 |
859 | # FreeCourses Menu
860 | elif english_courses == 100:
861 | FreeCourses()
862 |
863 | else:
864 | print(Fore.RED + '[!] Wrong Value')
865 | sleep(1.0)
866 | FreeCourses()
867 |
868 |
869 | # Close the script
870 | elif courses.lower() == 'exit':
871 | print(Fore.LIGHTCYAN_EX + '- Good Luck :)')
872 | now = datetime.now()
873 | print()
874 | print(Fore.LIGHTGREEN_EX + 'Quit time -> ' + Fore.LIGHTCYAN_EX + now.strftime("%m/%d/%Y %H:%M:%S"))
875 | print()
876 |
877 |
878 | else:
879 | print(Fore.RED + '[!] Wrong Value')
880 | sleep(1.0)
881 | FreeCourses()
882 |
883 | ##################################
884 | # <------CoDed By AnonCODER------>
885 | # <------v3.0----->
886 | # <------Now PyLe needs your support with its release------>
887 | # <------PyLe in Github : https://github.com/AnonC0DER/PyLe------>
888 |
--------------------------------------------------------------------------------
/database/data.json:
--------------------------------------------------------------------------------
1 | {
2 | "_comment" : "Trying for shorter codes :)",
3 |
4 | "Colors" : {
5 | "colored_dec": "\nVery simple Python library for color and formatting in terminal. \nCollection of color codes and names for 256 color terminal setups. \nThe following is a list of 256 colors for Xterm, containing an example of the displayed color, Xterm Name, Xterm Number and HEX.\n",
6 | "colored_exm": "\nHow to use the module in your own python code:\n\n>>> from colored import fg, bg, attr\n>>>\n>>> print ('%s Hello World !!! %s' % (fg(1), attr(0)))\n Hello World !!!\n>>>\n>>> print ('%s%s Hello World !!! %s' % (fg(1), bg(15), attr(0)))\n Hello World !!!\nUse description:\n\n>>> print ('%s%s Hello World !!! %s' % (fg('white'), bg('yellow'), attr('reset')))\n Hello World !!!\n>>>\n>>> print ('%s%s Hello World !!! %s' % (fg('orchid'), attr('bold'), attr('reset')))\n Hello World !!!\n>>>\n>>> color = bg('indian_red_1a') + fg('white')\n>>> reset = attr('reset')\n>>> print (color + 'Hello World !!!' + reset)\nHello World !!!\nOr use HEX code:\n\n>>> color = fg('#C0C0C0') + bg('#00005f')\n>>> res = attr('reset')\n>>> print (color + \"Hello World !!!\" + res)\nHello World !!!\n",
7 | "colorama_dec": "\nANSI escape character sequences have long been used to produce colored terminal text and cursor positioning on Unix and Macs. \nColorama makes this work on Windows, too, by wrapping stdout, stripping ANSI sequences it finds (which would appear as gobbledygook in the output), and converting them into the appropriate win32 calls to modify the state of the terminal. On other platforms, Colorama does nothing.\nThis has the upshot of providing a simple cross-platform API for printing colored terminal text from Python, and has the happy side-effect that existing applications or libraries which use ANSI sequences to produce colored output on Linux or Macs can now also work on Windows, simply by calling colorama.init()\nAn alternative approach is to install ansi.sys on Windows machines, which provides the same behaviour for all applications running in terminals. \nColorama is intended for situations where that isn\u2019t easy (e.g., maybe your app doesn\u2019t have an installer.)\n",
8 | "colorama_exm": "\nColored Output\nCross-platform printing of colored text can then be done using Colorama\u2019s constant shorthand for ANSI escape sequences:\n\nfrom colorama import Fore, Back, Style\nprint(Fore.RED + 'some red text')\nprint(Back.GREEN + 'and with a green background')\nprint(Style.DIM + 'and in dim text')\nprint(Style.RESET_ALL)\nprint('back to normal now')\n\n\u2026or, Colorama can be used in conjunction with existing ANSI libraries such as the venerable Termcolor or the fabulous Blessings. This is highly recommended for anything more than trivial coloring:\n\nfrom colorama import init\nfrom termcolor import colored\n\n# use Colorama to make Termcolor work on Windows too\ninit()\n\n# then use Termcolor for all colored text output\nprint(colored('Hello, World!', 'green', 'on_red'))\n",
9 | "termcolor_dec" : "Termcolor is a python module for ANSII Color formatting for output in terminal.",
10 | "termcolor_exm": "\nimport sys\nfrom termcolor import colored, cprint\n\ntext = colored('Hello, World!', 'red', attrs=['reverse', 'blink'])\nprint(text)\ncprint('Hello, World!', 'green', 'on_red')\n\nprint_red_on_cyan = lambda x: cprint(x, 'red', 'on_cyan')\nprint_red_on_cyan('Hello, World!')\nprint_red_on_cyan('Hello, Universe!')\n\nfor i in range(10):\n cprint(i, 'magenta', end=' ')\n\ncprint(\"Attention!\", 'red', attrs=['bold'], file=sys.stderr)\n"
11 | },
12 |
13 | "Machin_Learning" : {
14 | "scikit_dec": "\nScikit-learn is a Python module for machine learning built on top of SciPy and is distributed under the 3-Clause BSD license.\nThe project was started in 2007 by David Cournapeau as a Google Summer of Code project, and since then many volunteers have contributed.\nSee the About us page for a list of core contributors.\nIt is currently maintained by a team of volunteers.\n",
15 | "scikit_req": "\nScikit-learn requires:\n\n. Python (>= 3.6)\n. NumPy (>= 1.13.3)\n. SciPy (>= 0.19.1)\n. joblib (>= 0.11)\n. threadpoolctl (>= 2.0.0)\n",
16 | "keras_dec": "\nKeras is a deep learning API written in Python, running on top of the machine learning platform TensorFlow. \nIt was developed with a focus on enabling fast experimentation. \nBeing able to go from idea to result as fast as possible is key to doing good research.\n",
17 | "keras_exm": "\nSetup\nimport numpy as np\nimport tensorflow as tf\nimport matplotlib.pyplot as plt\nfrom tensorflow.keras import layers\nPrepare the dataset\nIn this example, we will be using the FashionMNIST dataset. But this same recipe can be used for other classification datasets as well.\n\n(x_train, y_train), (x_test, y_test) = tf.keras.datasets.fashion_mnist.load_data()\n\nx_train = x_train.astype(\"float32\") / 255.0\nx_train = np.reshape(x_train, (-1, 28, 28, 1))\ny_train = tf.one_hot(y_train, 10)\n\nx_test = x_test.astype(\"float32\") / 255.0\nx_test = np.reshape(x_test, (-1, 28, 28, 1))\ny_test = tf.one_hot(y_test, 10)\nDefine hyperparameters\nAUTO = tf.data.AUTOTUNE\nBATCH_SIZE = 64\nEPOCHS = 10\nConvert the data into TensorFlow Dataset objects\n# Put aside a few samples to create our validation set\nval_samples = 2000\nx_val, y_val = x_train[:val_samples], y_train[:val_samples]\nnew_x_train, new_y_train = x_train[val_samples:], y_train[val_samples:]\n\ntrain_ds_one = (\n tf.data.Dataset.from_tensor_slices((new_x_train, new_y_train))\n .shuffle(BATCH_SIZE * 100)\n .batch(BATCH_SIZE)\n)\ntrain_ds_two = (\n tf.data.Dataset.from_tensor_slices((new_x_train, new_y_train))\n .shuffle(BATCH_SIZE * 100)\n .batch(BATCH_SIZE)\n)\n# Because we will be mixing up the images and their corresponding labels, we will be\n# combining two shuffled datasets from the same training data.\ntrain_ds = tf.data.Dataset.zip((train_ds_one, train_ds_two))\n\nval_ds = tf.data.Dataset.from_tensor_slices((x_val, y_val)).batch(BATCH_SIZE)\n\ntest_ds = tf.data.Dataset.from_tensor_slices((x_test, y_test)).batch(BATCH_SIZE)\n",
18 | "xgboost_dec": "\nThat XGBoost is a library for developing fast and high performance gradient boosting tree models. \nThat XGBoost is achieving the best performance on a range of difficult machine learning tasks.\n",
19 | "xgboost_exm": "\n# First XGBoost model for Pima Indians dataset\nfrom numpy import loadtxt\nfrom xgboost import XGBClassifier\nfrom sklearn.model_selection import train_test_split\nfrom sklearn.metrics import accuracy_score\n# load data\ndataset = loadtxt('pima-indians-diabetes.csv', delimiter=\",\")\n# split data into X and y\nX = dataset[:,0:8]\nY = dataset[:,8]\n# split data into train and test sets\nseed = 7\ntest_size = 0.33\nX_train, X_test, y_train, y_test = train_test_split(X, Y, test_size=test_size, random_state=seed)\n# fit model no training data\nmodel = XGBClassifier()\nmodel.fit(X_train, y_train)\n# make predictions for test data\ny_pred = model.predict(X_test)\npredictions = [round(value) for value in y_pred]\n# evaluate predictions\naccuracy = accuracy_score(y_test, predictions)\nprint(\"Accuracy: %.2f%%\" % (accuracy * 100.0))\n",
20 | "statsmodels_dec": "\nStatsmodels is a Python package that provides a complement to scipy for statistical computations \nincluding descriptive statistics and estimation and inference for statistical models.\n",
21 | "statsmodels_exm": "\nThe Python Code using Statsmodels\nThe following Python code includes an example of Multiple Linear Regression, where the input variables are:\n\nInterest_Rate\nUnemployment_Rate\nThese two variables are used in the prediction of the dependent variable of Stock_Index_Price.\n\nHere is the complete syntax to perform the linear regression in Python using statsmodels (for larger datasets, you may consider to import your data):\n\nfrom pandas import DataFrame\nimport statsmodels.api as sm\n\nStock_Market = {'Year': [2017,2017,2017,2017,2017,2017,2017,2017,2017,2017,2017,2017,2016,2016,2016,2016,2016,2016,2016,2016,2016,2016,2016,2016],\n 'Month': [12, 11,10,9,8,7,6,5,4,3,2,1,12,11,10,9,8,7,6,5,4,3,2,1],\n 'Interest_Rate': [2.75,2.5,2.5,2.5,2.5,2.5,2.5,2.25,2.25,2.25,2,2,2,1.75,1.75,1.75,1.75,1.75,1.75,1.75,1.75,1.75,1.75,1.75],\n 'Unemployment_Rate': [5.3,5.3,5.3,5.3,5.4,5.6,5.5,5.5,5.5,5.6,5.7,5.9,6,5.9,5.8,6.1,6.2,6.1,6.1,6.1,5.9,6.2,6.2,6.1],\n 'Stock_Index_Price': [1464,1394,1357,1293,1256,1254,1234,1195,1159,1167,1130,1075,1047,965,943,958,971,949,884,866,876,822,704,719] \n }\n\ndf = DataFrame(Stock_Market,columns=['Year','Month','Interest_Rate','Unemployment_Rate','Stock_Index_Price']) \n\nX = df[['Interest_Rate','Unemployment_Rate']] # here we have 2 variables for the multiple linear regression. If you just want to use one variable for simple linear regression, then use X = df['Interest_Rate'] for example\nY = df['Stock_Index_Price']\n\nX = sm.add_constant(X) # adding a constant\n\nmodel = sm.OLS(Y, X).fit()\npredictions = model.predict(X) \n\nprint_model = model.summary()\nprint(print_model)\n",
22 | "tensorflow_dec": "\nTensorFlow is an open source software library for high performance numerical computation. \nIts flexible architecture allows easy deployment of computation across a variety of platforms (CPUs, GPUs, TPUs), \nand from desktops to clusters of servers to mobile and edge devices.\nOriginally developed by researchers and engineers from the Google Brain team within Google's AI organization, \nit comes with strong support for machine learning and deep learning and the flexible numerical computation core is used across many other scientific domains.\n",
23 | "tensorflow_exm": "\nExample :\nIn the code below, we defined two constant tensors and add one value to another:\n\nimport tensorflow as tf\n\nconst1 = tf.constant([[1,2,3], [1,2,3]]);\nconst2 = tf.constant([[3,4,5], [3,4,5]]);\n\nresult = tf.add(const1, const2);\n\nwith tf.Session() as sess:\n output = sess.run(result)\n print(output)\n",
24 | "numpy_dec": "NumPy is the fundamental package for scientific computing in Python. \nIt is a Python library that provides a multidimensional array object, \nvarious derived objects (such as masked arrays and matrices), \nand an assortment of routines for fast operations on arrays, \nincluding mathematical, logical, shape manipulation, sorting, selecting, I/O, \ndiscrete Fourier transforms, basic linear algebra, basic statistical operations, random simulation and much more.\nAt the core of the NumPy package, is the ndarray object. \nThis encapsulates n-dimensional arrays of homogeneous data types, \nwith many operations being performed in compiled code for performance.",
25 | "numpy_exm": ">>> import numpy as np\n>>> a = np.array([2,3,4])\n>>> a\narray([2, 3, 4])\n>>> a.dtype\ndtype('int64')\n>>> b = np.array([1.2, 3.5, 5.1])\n>>> b.dtype\ndtype('float64')",
26 | "scipy_dec": "\nSciPy is a collection of mathematical algorithms and convenience functions built on the NumPy \nextension of Python. It adds significant power to the interactive Python \nsession by providing the user with high-level commands and classes for manipulating \nand visualizing data. With SciPy, an interactive Python session becomes a data-processing \nand system-prototyping environment rivaling systems, such as MATLAB, IDL, Octave, R-Lab, and SciLab.\nThe additional benefit of basing SciPy on Python is that this also makes a powerful programming language \navailable for use in developing sophisticated programs and specialized applications. \nScientific applications using SciPy benefit from the development of additional modules \nin numerous niches of the software landscape by developers across the world. \nEverything from parallel programming to web and data-base subroutines and \nclasses have been made available to the Python programmer. \nAll of this power is available in addition to the mathematical libraries in SciPy.",
27 | "scipy_exm": "\nfrom scipy import special\ndef drumhead_height(n, k, distance, angle, t):\n kth_zero = special.jn_zeros(n, k)[-1]\n return np.cos(t) * np.cos(n*angle) * special.jn(n, distance*kth_zero)\ntheta = np.r_[0:2*np.pi:50j]\nradius = np.r_[0:1:50j]\nx = np.array([r * np.cos(theta) for r in radius])\ny = np.array([r * np.sin(theta) for r in radius])\nz = np.array([drumhead_height(1, 1, r, theta, 0.5) for r in radius])\n",
28 | "matplotlib_dec": "\nMatplotlib is a cross-platform, data visualization and graphical plotting library for Python \nand its numerical extension NumPy. As such, it offers a viable open source alternative to MATLAB. \nDevelopers can also use matplotlib\u2019s APIs (Application Programming Interfaces) \nto embed plots in GUI applications.",
29 | "matplotlib_exm": "\nimport matplotlib.pyplot as plt\nimport numpy as np\n\n\nlabels = ['G1', 'G2', 'G3', 'G4', 'G5']\nmen_means = [20, 34, 30, 35, 27]\nwomen_means = [25, 32, 34, 20, 25]\n\nx = np.arange(len(labels)) # the label locations\nwidth = 0.35 # the width of the bars\n\nfig, ax = plt.subplots()\nrects1 = ax.bar(x - width/2, men_means, width, label='Men')\nrects2 = ax.bar(x + width/2, women_means, width, label='Women')\n\n# Add some text for labels, title and custom x-axis tick labels, etc.\nax.set_ylabel('Scores')\nax.set_title('Scores by group and gender')\nax.set_xticks(x)\nax.set_xticklabels(labels)\nax.legend()\n\nax.bar_label(rects1, padding=3)\nax.bar_label(rects2, padding=3)\n\nfig.tight_layout()\n\nplt.show()",
30 | "seaborn_dec": "\nSeaborn is a library for making statistical graphics in Python. \nIt builds on top of matplotlib and integrates closely with pandas data structures.\nSeaborn helps you explore and understand your data. \nIts plotting functions operate on dataframes and arrays containing whole \ndatasets and internally perform the necessary semantic mapping and statistical aggregation to \nproduce informative plots. Its dataset-oriented, declarative API lets you focus on what the \ndifferent elements of your plots mean, rather than on the details of how to draw them.",
31 | "seaborn_exm": "\n# Import seaborn\nimport seaborn as sns\n\n# Apply the default theme\nsns.set_theme()\n\n# Load an example dataset\ntips = sns.load_dataset(\"tips\")\n\n# Create a visualization\nsns.relplot(\n data=tips,\n x=\"total_bill\", y=\"tip\", col=\"time\",\n hue=\"smoker\", style=\"smoker\", size=\"size\",\n)",
32 | "pytorch_dec": "\nPyTorch is an open source machine learning library based on the Torch library, \nused for applications such as computer vision and natural language processing, \nprimarily developed by Facebook's AI Research lab. It is free and open-source \nsoftware released under the Modified BSD license.",
33 | "pytorch_exm": "\nimport numpy as np\nimport math\n\n# Create random input and output data\nx = np.linspace(-math.pi, math.pi, 2000)\ny = np.sin(x)\n\n# Randomly initialize weights\na = np.random.randn()\nb = np.random.randn()\nc = np.random.randn()\nd = np.random.randn()\n\nlearning_rate = 1e-6\nfor t in range(2000):\n # Forward pass: compute predicted y\n # y = a + b x + c x^2 + d x^3\n y_pred = a + b * x + c * x ** 2 + d * x ** 3\n\n # Compute and print loss\n loss = np.square(y_pred - y).sum()\n if t % 100 == 99:\n print(t, loss)\n\n # Backprop to compute gradients of a, b, c, d with respect to loss\n grad_y_pred = 2.0 * (y_pred - y)\n grad_a = grad_y_pred.sum()\n grad_b = (grad_y_pred * x).sum()\n grad_c = (grad_y_pred * x ** 2).sum()\n grad_d = (grad_y_pred * x ** 3).sum()\n\n # Update weights\n a -= learning_rate * grad_a\n b -= learning_rate * grad_b\n c -= learning_rate * grad_c\n d -= learning_rate * grad_d\n\nprint(f'Result: y = {a} + {b} x + {c} x^2 + {d} x^3')",
34 | "pycaret_dec": "\nPyCaret is an open-source, low-code machine learning library in Python \nthat automates machine learning workflows. It is an end-to-end machine learning and model \nmanagement tool that speeds up the experiment cycle exponentially and makes you more productive.",
35 | "pycaret_exm1": "\n# Loading data from pycaret\nfrom pycaret.datasets import get_data\ndata = get_data('juice') ",
36 | "pycaret_exm2": "\n# Importing dataset\nfrom pycaret.datasets import get_data\ndiabetes = get_data('diabetes')\n# Importing module and initializing setup\nfrom pycaret.classification import *\nclf1 = setup(data = diabetes, target = 'Class variable')\n# train a votingclassifier on all models in library\nblender = blend_models()\n# train a voting classifier on specific models\ndt = create_model('dt')\nrf = create_model('rf')\nadaboost = create_model('ada')\nblender_specific = blend_models(estimator_list = [dt,rf,adaboost], method = 'soft')\n# train a voting classifier dynamically\nblender_specific = blend_models(estimator_list = compare_models(n_select = 5), method = 'hard')"
37 | },
38 |
39 | "Telegram_bots" : {
40 | "python_telegram_bot_dec": "\nThis library provides a pure Python interface for the Telegram Bot API. It\u2019s compatible with Python versions 3.6+. PTB might also work on PyPy, though there have been a lot of issues before. Hence, PyPy is not officially supported.\nIn addition to the pure API implementation, this library features a number of high-level classes to make the development of bots easy and straightforward. These classes are contained in the telegram.ext submodule.\n",
41 | "python_telegram_bot_exm": "\nThis library uses the logging module. To set up logging to standard output, put:\n\nimport logging\nlogging.basicConfig(level=logging.DEBUG,\n format='%(asctime)s - %(name)s - %(levelname)s - %(message)s')\nat the beginning of your script.\n\nYou can also use logs in your application by calling logging.getLogger() and setting the log level you want:\n\nlogger = logging.getLogger()\nlogger.setLevel(logging.INFO)\nIf you want DEBUG logs instead:\n\nlogger.setLevel(logging.DEBUG)\n",
42 | "pyrogram_dec": "Pyrogram is a modern, elegant and easy-to-use Telegram client library framework written from the ground up in Python and C. It enables you to easily create custom Telegram client applications for both user and bot identities (bot API alternative) via the MTProto API.",
43 | "pyrogram_req": "\nRequirements\n\n-Python 3.6 or higher.\n-A Telegram API key.",
44 | "pyrogram_exm": "\nfrom pyrogram import Client, filters\n\napp = Client(\"my_account\")\n\n\n@app.on_message(filters.private)\nasync def hello(client, message):\n await message.reply_text(f\"Hello {message.from_user.mention}\")\n\n\napp.run()",
45 | "telegram_dec": "\nAn async API wrapper for Telegram bot API in Python\nPython 3.7+ is required to install and use telegram.py",
46 | "telegram_exm": "\nimport logging\n\nimport telegrampy\nfrom telegrampy.ext import commands\n\nlogging.basicConfig(level=logging.INFO, format=\"(%(asctime)s) %(levelname)s %(message)s\", datefmt=\"%m/%d/%y - %H:%M:%S %Z\")\nlogger = logging.getLogger(\"telegrampy\")\n\nbot = commands.Bot(\"token here\")\n\n@bot.command()\nasync def hi(ctx):\n await ctx.send(\"Hello\")\n\nbot.run()"
47 | },
48 |
49 | "game_devel" : {
50 | "pygame_dec": "\nPygame is a free and open-source cross-platform library for the development of multimedia applications\nlike video games using Python. It uses the Simple DirectMedia Layer library and\nseveral other popular libraries to abstract the most common functions, \nmaking writing these programs a more intuitive task.",
51 | "pygame_exm": "\n# Simple pygame program\n\n# Import and initialize the pygame library\nimport pygame\npygame.init()\n\n# Set up the drawing window\nscreen = pygame.display.set_mode([500, 500])\n\n# Run until the user asks to quit\nrunning = True\nwhile running:\n\n # Did the user click the window close button?\n for event in pygame.event.get():\n if event.type == pygame.QUIT:\n running = False\n\n # Fill the background with white\n screen.fill((255, 255, 255))\n \n # Draw a solid blue circle in the center\n pygame.draw.circle(screen, (0, 0, 255), (250, 250), 75)\n\n # Flip the display\n pygame.display.flip()\n\n# Done! Time to quit.\npygame.quit()",
52 | "turtles_dec": "\nTurtle graphics is a popular way for introducing programming to kids. \nIt was part of the original Logo programming language developed by Wally Feurzeig, \nSeymour Papert and Cynthia Solomon in 1967.",
53 | "turtles_exm": "\nimport turtle \n\nninja = turtle.Turtle()\n\nninja.speed(10)\n\nfor i in range(180):\n ninja.forward(100)\n ninja.right(30)\n ninja.forward(20)\n ninja.left(60)\n ninja.forward(50)\n ninja.right(30)\n \n ninja.penup()\n ninja.setposition(0, 0)\n ninja.pendown()\n\n ninja.right(2)\n \nturtle.done()",
54 | "pyopengl_dec": "\nPyOpenGL is the most common cross platform Python binding to OpenGL and related APIs. \nThe binding is created using the standard ctypes library, \nand is provided under an extremely liberal BSD-style Open-Source license.",
55 | "pyopengl_exm": "\nfrom OpenGL.GL import *\nfrom OpenGL.GLUT import *\nfrom OpenGL.GLU import *\n\nwindow = 0 # glut window number\nwidth, height = 500, 400 # window size\n\ndef draw(): # ondraw is called all the time\n glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT) # clear the screen\n glLoadIdentity() # reset position\n \n # ToDo draw rectangle\n \n glutSwapBuffers() # important for double buffering\n \n\n# initialization\nglutInit() # initialize glut\nglutInitDisplayMode(GLUT_RGBA | GLUT_DOUBLE | GLUT_ALPHA | GLUT_DEPTH)\nglutInitWindowSize(width, height) # set window size\nglutInitWindowPosition(0, 0) # set window position\nwindow = glutCreateWindow(\"noobtuts.com\") # create window with title\nglutDisplayFunc(draw) # set draw function callback\nglutIdleFunc(draw) # draw all the time\nglutMainLoop() # start everything"
56 | },
57 |
58 | "file_enc" : {
59 | "cryptography_dec": "\nCryptography is a package which provides cryptographic recipes and primitives to Python developers. \nOur goal is for it to be your \u201ccryptographic standard library\u201d. \nIt supports Python 3.6+ and PyPy3 7.2+.\nCryptography includes both high level recipes and low level interfaces to common cryptographic \nalgorithms such as symmetric ciphers, message digests, \nand key derivation functions.",
60 | "cryptography_exm": "\n>>> from cryptography.fernet import Fernet\n>>> # Put this somewhere safe!\n>>> key = Fernet.generate_key()\n>>> f = Fernet(key)\n>>> token = f.encrypt(b\"A really secret message. Not for prying eyes.\")\n>>> token\nb'...'\n>>> f.decrypt(token)\nb'A really secret message. Not for prying eyes.",
61 | "pycrypto_dec": "\nThis is a collection of both secure hash functions (such as SHA256 and RIPEMD160), \nand various encryption algorithms (AES, DES, RSA, ElGamal, etc.). \nThe package is structured to make adding new modules easy. This section is essentially complete, \nand the software interface will almost certainly not change in an incompatible way in the future; \nall that remains to be done is to fix any bugs that show up.",
62 | "pycrypto_exm": "\n>>> from Crypto.Cipher import AES\n>>> obj = AES.new('This is a key123', AES.MODE_CBC, 'This is an IV456')\n>>> message = \"The answer is no\"\n>>> ciphertext = obj.encrypt(message)\n>>> obj2 = AES.new('This is a key123', AES.MODE_CBC, 'This is an IV456')\n>>> obj2.decrypt(ciphertext)\n'The answer is no' ",
63 | "pyaescrypt_dec": "\npyAesCrypt is a Python 3 file-encryption module and script that \nuses AES256-CBC to encrypt/decrypt files and binary streams.\npyAesCrypt is compatible with the AES Crypt file format (version 2).\nIt is Free Software, released under the Apache License, Version 2.0.\npyAesCrypt is brought to you by Marco Bellaccini - marco.bellaccini(at!)gmail.com.\nIMPORTANT SECURITY NOTE: version 2 of the AES Crypt file format does not authenticate the \u201cfile size modulo 16\u201d byte. \nThis implies that an attacker with write access to the encrypted file may \nalter the corresponding plaintext file size by up to 15 bytes.\nthere is no low-level memory management in Python, hence it is not possible to wipe \nmemory areas were sensitive information was stored.",
64 | "pyaescrypt_exm": "\nimport pyAesCrypt\n# encryption/decryption buffer size - 64K\nbufferSize = 64 * 1024\npassword = \"foopassword\"\n# encrypt\npyAesCrypt.encryptFile(\"data.txt\", \"data.txt.aes\", password, bufferSize)\n# decrypt\npyAesCrypt.decryptFile(\"data.txt.aes\", \"dataout.txt\", password, bufferSize)"
65 | },
66 |
67 | "sqllib" : {
68 | "sqlite_dec": "\nSQLite is a C library that provides a lightweight disk-based database that doesn\u2019t require \na separate server process and allows accessing the database using a nonstandard \nvariant of the SQL query language. Some applications can use SQLite for internal data storage. \nIt\u2019s also possible to prototype an application using SQLite and then port the code \nto a larger database such as PostgreSQL or Oracle.\nThe sqlite3 module was written by Gerhard H\u00e4ring. It provides a SQL interface \ncompliant with the DB-API 2.0 specification described by PEP 249.",
69 | "sqlite_exm": "\nimport sqlite3\ncon = sqlite3.connect('example.db')\ncur = con.cursor()\n\n# Create table\ncur.execute('''CREATE TABLE stocks\n(date text, trans text, symbol text, qty real, price real)''')\n\n# Insert a row of data\ncur.execute(\"INSERT INTO stocks VALUES ('2006-01-05','BUY','RHAT',100,35.14)\")\n\n# Save (commit) the changes\ncon.commit()\n\n# We can also close the connection if we are done with it.\n# Just be sure any changes have been committed or they will be lost.\ncon.close()",
70 | "mysql_dec": "\nMySQL Connector/Python enables Python programs to access MySQL databases, \nusing an API that is compliant with the Python Database API Specification v2.0 (PEP 249).",
71 | "mysql_exm": "\nimport mysql.connector\nfrom mysql.connector import Error\n\ndef create_connection(host_name, user_name, user_password):\n connection = None\n try:\n connection = mysql.connector.connect(\n host=host_name,\n user=user_name,\n passwd=user_password)\n print(\"Connection to MySQL DB successful\")\n except Error as e:\n print(f\"The error '{e}' occurred\")\n\n return connection\n\nconnection = create_connection(\"localhost\", \"root\", \"\")",
72 | "postgres_dec": "\nPostgreSQL is one of the most advanced and widely used relational database management systems. \nIt's extremely popular for many reasons, a few of which include it being open source, \nits extensibility, and its ability to handle many different types of applications and varying loads.\nWith Python, you can easily establish a connection to your PostgreSQL database. \nThere are many Python drivers for PostgreSQL, with \"psycopg\" being the most popular one. \nIts current version is psycopg2.\nIn this article, we'll be discussing how to access a PostgreSQL database \nin Python using the psycopg2 driver.",
73 | "postgres_exm": "\nimport psycopg2\n\ncon = psycopg2.connect(database=\"postgres\", user=\"postgres\", password=\"Kaliakakya\", host=\"127.0.0.1\", port=\"5432\")\nprint(\"Database opened successfully\")\n\ncur = con.cursor()\n\ncur.execute(\"INSERT INTO STUDENT (ADMISSION,NAME,AGE,COURSE,DEPARTMENT) VALUES (3419, 'Abel', 17, 'Computer Science', 'ICT')\");\ncur.execute(\"INSERT INTO STUDENT (ADMISSION,NAME,AGE,COURSE,DEPARTMENT) VALUES (3421, 'Joel', 17, 'Computer Science', 'ICT')\");\ncur.execute(\"INSERT INTO STUDENT (ADMISSION,NAME,AGE,COURSE,DEPARTMENT) VALUES (3422, 'Antony', 19, 'Electrical Engineering', 'Engineering')\");\ncur.execute(\"INSERT INTO STUDENT (ADMISSION,NAME,AGE,COURSE,DEPARTMENT) VALUES (3423, 'Alice', 18, 'Information Technology', 'ICT')\");\n\ncon.commit()\nprint(\"Records inserted successfully\")\ncon.close()"
74 | },
75 |
76 | "other" : {
77 | "os_dec": "\nThe OS module in Python provides functions for interacting with the operating system. \nOS comes under Python's standard utility modules. \nThis module provides a portable way of using operating system dependent functionality. \nThe *os* and *os. path* modules include many functions to interact with the file system",
78 | "os_exm": "\nfrom os import system\nsystem('clear')\n",
79 | "subprocess_dec": "\nThe subprocess module present in Python(both 2. ... x) is used to run new applications or \nprograms through Python code by creating new processes. \nIt also helps to obtain the input/output/error pipes as well as the exit codes of various commands.\n",
80 | "subprocess_exm": "\nimport subprocess\nimport sys\n\n# create two files to hold the output and errors, respectively\nwith open('out.txt','w+') as fout:\nwith open('err.txt','w+') as ferr:\n out=subprocess.call([\"ls\",'-lha'],stdout=fout,stderr=ferr)\n # reset file to read from it\n fout.seek(0)\n # save output (if any) in variable\n output=fout.read())\n\n # reset file to read from it\n ferr.seek(0) \n # save errors (if any) in variable\n errors = ferr.read()\n",
81 | "urllib_request_dec": "\nThe urllib.request module defines functions and classes which help\nin opening URLs (mostly HTTP) in a complex world \u2014 basic and digest authentication, \nredirections, cookies and more. ... Open the URL url, which can be either a string or a Request object.\n",
82 | "urllib_request_exm": "\n>>> import urllib.request\n>>> with urllib.request.urlopen('http://www.python.org/') as f:\n... print(f.read(300))\n",
83 | "requests_dec": "\nThe requests library is the de facto standard for making HTTP requests in Python. \nIt abstracts the complexities of making requests behind a beautiful, \nsimple API so that you can focus on interacting with services and consuming data in your application.\n",
84 | "requests_exm": "\nimport requests\nfrom requests.exceptions import HTTPError\n\nfor url in ['https://api.github.com', 'https://api.github.com/invalid']:\ntry:\n response = requests.get(url)\n\n # If the response was successful, no Exception will be raised\n response.raise_for_status()\nexcept HTTPError as http_err:\n print(f'HTTP error occurred: {http_err}') # Python 3.6\n except Exception as err:\n print(f'Other error occurred: {err}') # Python 3.6\n else:\n print('Success!')\n",
85 | "tkinter_dec": "\nTkinter is Python's de-facto standard GUI (Graphical User Interface) package. \nIt is a thin object-oriented layer on top of Tcl/Tk. Tkinter is not the only \nGuiProgramming toolkit for Python. It is however the most commonly used one. ... Graphical User \nInterfaces with Tk, a chapter from the Python Documentation.\n",
86 | "tkinter_exm": "\nfrom tkinter import *\n\nwindow = Tk()\n\nwindow.title(\"Welcome to LikeGeeks app\")\n\nlbl = Label(window, text=\"Hello\")\n\nlbl.grid(column=0, row=0)\n\nwindow.mainloop()",
87 | "pyqt_dec": "\nPyQt is a set of Python bindings for The Qt Company's Qt application framework and \nruns on all platforms supported by Qt including Windows, macOS, Linux, iOS and Android. \nPyQt6 supports Qt v6, PyQt5 supports Qt v5 and PyQt4 supports Qt v4. \nThe bindings are implemented as a set of Python modules and contain over 1,000 classes.\n",
88 | "pyqt_exm": "\nimport sys\nfrom PyQt5.QtWidgets import QApplication, QWidget\n\n\ndef main():\n\n app = QApplication(sys.argv)\n\n w = QWidget()\n w.resize(250, 150)\n w.move(300, 300)\n w.setWindowTitle('Simple')\n w.show()\n\n sys.exit(app.exec_())\n\n\nif __name__ == '__main__':\n main()\n",
89 | "moviepy_dec": "\nMoviePy (full documentation) is a Python library for \nvideo editing: cutting, concatenations, title insertions, video compositing (a.k.a. non-linear editing), \nvideo processing, and creation of custom effects.\n",
90 | "moviepy_exm": "\nfrom moviepy import *\n\nvideo = VideoFileClip(\"myHolidays.mp4\").subclip(50,60)\n\n# Make the text. Many more options are available.\ntxt_clip = ( TextClip(\"My Holidays 2013\",fontsize=70,color='white')\n .with_position('center')\n .with_duration(10) )\n \n# Overlay text on video\nresult = CompositeVideoClip([video, txt_clip])\nresult.write_videofile(\"myHolidays_edited.webm\",fps=25) # Many options...\n",
91 | "datetime_dec": "\nDatetime module supplies classes to work with date and time. \nThese classes provide a number of functions to deal with dates, times and time intervals. \nDate and datetime are an object in Python, so when you manipulate them, \nyou are actually manipulating objects and not string or timestamps.\n",
92 | "datetime_exm": "\n>>> import time\n>>> from datetime import date\n>>> today = date.today()\n>>> today\ndatetime.date(2007, 12, 5)\n>>> today == date.fromtimestamp(time.time())\nTrue\n>>> my_birthday = date(today.year, 6, 24)\n>>> if my_birthday < today:\n... my_birthday = my_birthday.replace(year=today.year + 1)\n>>> my_birthday\ndatetime.date(2008, 6, 24)\n>>> time_to_birthday = abs(my_birthday - today)\n>>> time_to_birthday.days\n202\n",
93 | "pendulum_dec": "\nUnlike other datetime libraries for Python, Pendulum is a drop-in replacement for \nthe standard datetime class (it inherits from it), so, basically, you can \nreplace all your datetime instances by DateTime instances in \nyou code (exceptions exist for libraries that check the type of the objects \nby using the type function like sqlite3 or PyMySQL for instance).\n",
94 | "pendulum_exm": "\nimport pendulum\n\nin_utc = pendulum.datetime(2013, 3, 31, 0, 59, 59)\ntz = pendulum.timezone(\"Europe/Paris\")\nin_paris = tz.convert(in_utc)\n'2013-03-31T01:59:59+01:00'\n\n# Shifting time\nin_paris = in_paris.add(seconds=1)\n'2013-03-31T03:00:00+02:00'\nin_paris.subtract(seconds=1)\n'2013-03-31T01:59:59+01:00'\n",
95 | "pillow_dec": "\nPillow is a Python Imaging Library (PIL), which adds support for opening, manipulating, and saving images. \nThe current version identifies and reads a large number of formats. \nWrite support is intentionally restricted to the most commonly used interchange and presentation formats.\n",
96 | "pillow_exm": "\nfrom PIL import Image\nimport glob, os\n\nsize = 128, 128\n\nfor infile in glob.glob(\"*.jpg\"):\n file, ext = os.path.splitext(infile)\nwith Image.open(infile) as im:\n im.thumbnail(size)\n im.save(file + \".thumbnail\", \"JPEG\")\n",
97 | "opencvpython_dec": "\nOpenCV-Python is a library of Python bindings designed to solve computer vision problems.\nPython is a general purpose programming language started by Guido van Rossum that became \nvery popular very quickly, mainly because of its simplicity and code readability. \nIt enables the programmer to express ideas in fewer lines of code without reducing readability.\nCompared to languages like C/C++, Python is slower. \nThat said, Python can be easily extended with C/C++, which allows us to write computationally \nintensive code in C/C++ and create Python wrappers that can be used as Python modules. \nThis gives us two advantages: first, the code is as fast as the original C/C++ code \n(since it is the actual C++ code working in background) and second, it easier to code in Python than C/C++. \nOpenCV-Python is a Python wrapper for the original OpenCV C++ implementation.\nOpenCV-Python makes use of Numpy, which is a highly optimized\nlibrary for numerical operations with a MATLAB-style syntax. \nAll the OpenCV array structures are converted to and from Numpy arrays. \nThis also makes it easier to integrate with other libraries that use Numpy such as SciPy and Matplotlib.\n",
98 | "opencvpython_exm": "\nimport cv2\nimport numpy as np\nfrom matplotlib import pyplot as plt\n\nimg = cv2.imread('watch.jpg',cv2.IMREAD_GRAYSCALE)\ncv2.imshow('image',img)\ncv2.waitKey(0)\ncv2.destroyAllWindows()\n",
99 | "theano_dec": "\nTheano is a Python library that lets you define mathematical expressions used in Machine Learning, \noptimize these expressions and evaluate those very efficiently by decisively \nusing GPUs in critical areas. It can rival typical full C-implementations in most of the cases.\nTheano was written at the LISA lab with the intention of providing rapid development \nof efficient machine learning algorithms. It is released under a BSD license.\n",
100 | "theano_exm": "\nfrom theano import *\na = tensor.dmatrix()\nb = tensor.dmatrix()\nc = tensor.dot(a,b)\nf = theano.function([a,b], c)\nd = f([[0, -1, 2],[4, 11, 2]], [[3, -1],[1,2],[6,1]])\nprint (d)\n",
101 | "fire_dec": "\nPython Fire is a library for automatically generating command line interfaces (CLIs) with a single line of code.\nIt will turn any Python module, class, object, function, etc. (any Python component will work!) into a CLI. \nIt\u2019s called Fire because when you call Fire(), it fires off your command.\n",
102 | "fire_exm": "\nimport fire\nclass IngestionStage(object):\n\n def run(self):\n return 'Ingesting! Nom nom nom...'\n\nclass DigestionStage(object):\n\n def run(self, volume=1):\n return ' '.join(['Burp!'] * volume)\n\n def status(self):\n return 'Satiated.'\n\nclass Pipeline(object):\n\n def __init__(self):\n self.ingestion = IngestionStage()\n self.digestion = DigestionStage()\n\n def run(self):\n self.ingestion.run()\n self.digestion.run()\n\nif __name__ == '__main__':\n fire.Fire(Pipeline)\n",
103 | "arrow_dec": "\nArrow is a Python library that offers a sensible and human-friendly approach to creating, \nmanipulating, formatting and converting dates, times and timestamps. \nIt implements and updates the datetime type, plugging gaps in functionality and providing \nan intelligent module API that supports many common creation scenarios. \nSimply put, it helps you work with dates and times with fewer imports and a lot less code.\n",
104 | "arrow_exm": "\n>>> import arrow\n>>> arrow.get('2013-05-11T21:23:58.970460+07:00')\n\n\n>>> utc = arrow.utcnow()\n>>> utc\n\n\n>>> utc = utc.shift(hours=-1)\n>>> utc\n\n\n>>> local = utc.to('US/Pacific')\n>>> local\n\n\n>>> local.timestamp()\n1368303838.970460\n\n>>> local.format()\n'2013-05-11 13:23:58 -07:00'\n\n>>> local.format('YYYY-MM-DD HH:mm:ss ZZ')\n'2013-05-11 13:23:58 -07:00'\n\n>>> local.humanize()\n'an hour ago'\n",
105 | "flashtext_dec": "\nThis module can be used to replace keywords in sentences or extract keywords from sentences. \nIt is based on the FlashText algorithm.\n",
106 | "flashtext_exm": "\n>>> from flashtext import KeywordProcessor\n>>> keyword_processor = KeywordProcessor()\n>>> keyword_processor.add_keyword('j2ee', 'Java')\n>>> 'j2ee' in keyword_processor\n>>> # output: True\n>>> keyword_processor.get_keyword('j2ee')\n>>> # output: Java\n>>> keyword_processor['colour'] = 'color'\n>>> keyword_processor['colour']\n>>> # output: color\n",
107 | "wxpython_dec": "\nwxPython is a cross-platform GUI toolkit for the Python programming language. \nIt allows Python programmers to create programs with a robust, \nhighly functional graphical user interface, simply and easily. \nIt is implemented as a set of Python extension modules that wrap the GUI components of \nthe popular wxWidgets cross platform library, which is written in C++.\n",
108 | "wxpython_exm": "\n# First things, first. Import the wxPython package.\nimport wx\n\n# Next, create an application object.\napp = wx.App()\n\n# Then a frame.\nfrm = wx.Frame(None, title=\"Hello World\")\n\n# Show it.\nfrm.Show()\n\n# Start the event loop.\napp.MainLoop()\n",
109 | "cirq_dec": "\nAn open source framework for programming quantum computers.\nCirq is a Python software library for writing, manipulating, and optimizing quantum circuits, \nand then running them on quantum computers and quantum simulators. \nCirq provides useful abstractions for dealing with today\u2019s noisy intermediate-scale \nquantum computers, where details of the hardware are vital to achieving state-of-the-art results.\n",
110 | "cirq_exm": "\nimport cirq\n\n# Pick a qubit.\nqubit = cirq.GridQubit(0, 0)\n\n# Create a circuit\ncircuit = cirq.Circuit(\n cirq.X(qubit)**0.5, # Square root of NOT.\n cirq.measure(qubit, key='m') # Measurement.\n)\nprint(\"Circuit:\")\nprint(circuit)\n\n# Simulate the circuit several times.\nsimulator = cirq.Simulator()\nresult = simulator.run(circuit, repetitions=20)\nprint(\"Results:\")\nprint(result)\n",
111 | "json_dec": "\nJSON in Python is a standard format inspired by JavaScript for data \nexchange and data transfer as text format over a network.\nGenerally, JSON is in string or text format. \nIt can be used by APIs and databases, and it represents objects as name/value pairs. \nJSON stands for JavaScript Object Notation.\n",
112 | "json_exm": "\n>>> import json\n>>> json.loads('[\"foo\", {\"bar\":[\"baz\", null, 1.0, 2]}]')\n['foo', {'bar': ['baz', None, 1.0, 2]}]\n>>> json.loads('\"\\\"foo\\bar\"')\n'\"foo\bar'\n>>> from io import StringIO\n>>> io = StringIO('[\"streaming API\"]')\n>>> json.load(io)\n['streaming API']\n",
113 | "sys_dec": "\nThis module provides access to some variables used or maintained by the interpreter \nand to functions that interact strongly with the interpreter. It is always available.\n",
114 | "sys_exm": "\n>>> import sys\n>>>sys.path\n['', 'C:\\python36\\Lib\\idlelib', 'C:\\python36\\python36.zip', \n'C:\\python36\\DLLs', 'C:\\python36\\lib', 'C:\\python36',\n'C:\\Users\\acer\\AppData\\Roaming\\Python\\Python36\\site-packages', \n'C:\\python36\\lib\\site-packages']\n",
115 | "instapy_dec": "\nTooling that automates your social media interactions to \"farm\" Likes, Comments, \nand Followers on Instagram implemented in Python using the Selenium module.\n",
116 | "instapy_exm": "\nfrom instapy import InstaPy\nsession = InstaPy(username=\"test\", password=\"test1111\")\nsession.login()\nsession.end\nquit()\n",
117 | "cython_dec": "\nCython is an optimising static compiler for both the Python programming language \nand the extended Cython programming language (based on Pyrex). \nIt makes writing C extensions for Python as easy as Python itself.\n",
118 | "cython_exm": "\ndef primes(nb_primes: cython.int):\n i: cython.int\n p: cython.int[1000]\n\n if nb_primes > 1000:\n nb_primes = 1000\n\n if not cython.compiled: # Only if regular Python is running\n p = [0] * 1000 # Make p work almost like a C array\n\n len_p: cython.int = 0 # The current number of elements in p.\n n: cython.int = 2\n while len_p < nb_primes:\n # Is n prime?\n for i in p[:len_p]:\n if n % i == 0:\n break\n\n # If no break occurred in the loop, we have a prime.\n else:\n p[len_p] = n\n len_p += 1\n n += 1\n\n # Let's copy the result into a Python list:\n result_as_list = [prime for prime in p[:len_p]]\n return result_as_list\n",
119 | "pytube_dec": "\npytube is a very serious, lightweight, dependency-free \nPython library (and command-line utility) for downloading YouTube Videos.\n",
120 | "pytube_exm": "\n>>> from pytube import YouTube\n>>> YouTube('https://youtu.be/9bZkp7q19f0').streams.first().download()\n>>> yt = YouTube('http://youtube.com/watch?v=9bZkp7q19f0')\n>>> yt.streams\n... .filter(progressive=True, file_extension='mp4')\n... .order_by('resolution')\n... .desc()\n... .first()\n... .download()\n",
121 | "typer_dec": "\nTyper is a library for building CLI applications that users will love using and developers will love creating. \nBased on Python 3.6+ type hints.\n",
122 | "typer_exm": "\nimport typer\n\napp = typer.Typer()\n\n\n@app.command()\ndef hello(name: str):\n typer.echo(f\"Hello {name}\")\n\n\n@app.command()\ndef goodbye(name: str, formal: bool = False):\n if formal:\n typer.echo(f\"Goodbye Ms. {name}. Have a good day.\")\n else:\n typer.echo(f\"Bye {name}!\")\n\n\nif __name__ == \"__main__\":\n app()\n",
123 | "rich_dec": "\nRich is a Python library for writing rich text (with color and style) to the terminal, \nand for displaying advanced content such as tables, markdown, and syntax highlighted code.\nUse Rich to make your command line applications visually \nappealing and present data in a more readable way. \nRich can also be a useful debugging aid by pretty printing and syntax highlighting data structures.\n",
124 | "rich_exm": "\nfrom typing import List\nfrom rich.console import Console, OverflowMethod\n\nconsole = Console(width=14)\nsupercali = \"supercalifragilisticexpialidocious\"\n\noverflow_methods: List[OverflowMethod] = [\"fold\", \"crop\", \"ellipsis\"]\nfor overflow in overflow_methods:\n console.rule(overflow)\nconsole.print(supercali, overflow=overflow, style=\"bold blue\")\n console.print()\n",
125 | "dearpygui_dec": "\nWelcome to the Dear PyGui wiki! Always in construction - feel free to edit and contribute!\nDear PyGui is an easy-to-use, dynamic, GPU-Accelerated, \ncross-platform graphical user interface (GUI) framework for Python. \nAs an extended wrapping of Dear ImGui, Dear PyGui is highly performant. \nIt is written primarily in C/C++ and uses your GPU for rendering.\nFeatures include traditional GUI elements to display text, images and various controls, \nsuch as buttons, radio buttons, and menus and various methods to create a functional and \nbeautiful layout. Additionally, it offers incredibly dynamic charts, tables, drawings and tools \nfor application development, such as built-in documentation, logging, and debugger.\nAs a GUI toolkit, it is well suited for creating simple user interfaces to wrap basic\ncommand line interfaces as well as to developing complex and demanding graphical interfaces. \nIt offers a solid framework for developing science, engineering, games, data science and other \napplications that require fast and interactive interfaces.\n",
126 | "dearpygui_exm": "\nimport dearpygui.dearpygui as dpg\n\nwith dpg.window(label=\"Tutorial\"):\n\n dpg.add_button(label=\"Apply\")\n dpg.add_same_line(spacing=10)\n dpg.add_button(label=\"Apply\")\n dpg.add_same_line(spacing=10)\n dpg.add_button(label=\"Apply\")\n dpg.add_spacing(count=5)\n\n # printing the widgets unique id\n id=dpg.add_button(label=\"Press me\")\n print(id)\n\ndpg.start_dearpygui() \n",
127 | "prettyErrors_dec" : "Prettify Python exception output to make it legible.",
128 | "prettyErrors_exm": "\nimport pretty_errors\npretty_errors.configure(\n separator_character = '*',\n filename_display = pretty_errors.FILENAME_EXTENDED,\n line_number_first = True,\n display_link = True,\n lines_before = 5,\n lines_after = 2,\n line_color = pretty_errors.RED + '> ' + pretty_errors.default_config.line_color,\n code_color = ' ' + pretty_errors.default_config.line_color,\n truncate_code = True,\n display_locals = True\n)\npretty_errors.blacklist('c:/python')\n",
129 | "diagrams_dec": "\nDiagrams lets you draw the cloud system architecture in Python code. \nIt was born for prototyping a new system architecture design without any design tools. \nYou can also describe or visualize the existing system architecture as well. \nDiagrams currently supports main major providers including: AWS, Azure, GCP, \nKubernetes, Alibaba Cloud, Oracle Cloud etc... It also supports On-Premise nodes, \nSaaS and major Programming frameworks and languages.\nDiagram as Code also allows you to track the architecture diagram changes in any version control system.\n",
130 | "diagrams_exm": "\nfrom diagrams import Diagram\nfrom diagrams.aws.compute import EC2\n\ngraph_attr = {\n \"fontsize\": \"45\",\n \"bgcolor\": \"transparent\"\n}\n\nwith Diagram(\"Simple Diagram\", show=False, graph_attr=graph_attr):\n EC2(\"web\")\n",
131 | "hiplot_dec": "\nHiPlot is a lightweight interactive visualization tool to help AI \nresearchers discover correlations and patterns in high-dimensional \ndata using parallel plots and other graphical ways to represent information.\n",
132 | "hiplot_exm": "\n# my_fetcher.py\nfrom pathlib import Path\nimport hiplot as hip\ndef fetch_my_experiment(uri):\n # Only apply this fetcher if the URI starts with myxp://\n PREFIX=\"myxp://\"\n if not uri.startswith(PREFIX):\n # Let other fetchers handle this one\n raise hip.ExperimentFetcherDoesntApply()\n uri = uri[len(PREFIX):] # Remove the prefix\n\n return hip.Experiment.from_csv(uri + '/data.csv')\n",
133 | "selenium_dec": "\nSelenium Python bindings provides a simple API to write \nfunctional/acceptance tests using Selenium WebDriver.\nThrough Selenium Python API you can access all functionalities \nof Selenium WebDriver in an intuitive way.\nSelenium Python bindings provide a convenient API to access\nSelenium WebDrivers like Firefox, Ie, Chrome, Remote etc. \nThe current supported Python versions are 3.5 and above.\n ",
134 | "selenium_exm": "\nfrom selenium import webdriver\nfrom selenium.webdriver.common.keys import Keys\n\ndriver = webdriver.Firefox()\ndriver.get(\"http://www.python.org\")\nassert \"Python\" in driver.title\nelem = driver.find_element_by_name(\"q\")\nelem.clear()\nelem.send_keys(\"pycon\")\nelem.send_keys(Keys.RETURN)\nassert \"No results found.\" not in driver.page_source\ndriver.close()\n",
135 | "pandas_dec": "\nPandas is a fast, powerful, flexible and easy to use open source data analysis and manipulation tool,\nbuilt on top of the Python programming language.\n ",
136 | "pandas_exm": "\nIn [1]: import pandas as pd\nIn [2]: df = pd.DataFrame(\n ...: {\n ...: \"Name\": [\n ...: \"Braund, Mr. Owen Harris\",\n ...: \"Allen, Mr. William Henry\",\n ...: \"Bonnell, Miss. Elizabeth\",\n ...: ],\n ...: \"Age\": [22, 35, 58],\n ...: \"Sex\": [\"male\", \"male\", \"female\"],\n ...: }\n ...: )\n ...: \n\nIn [3]: df\nOut[3]: \nName Age Sex\n0 Braund, Mr. Owen Harris 22 male\n1 Allen, Mr. William Henry 35 male\n2 Bonnell, Miss. Elizabeth 58 female\n ",
137 | "delorean_dec": "\nDelorean is the name of the car in the movie Back to the Future. \nThe movie deals with a lot of time travel, hence the name Delorean as a module dealing with datetimes.\nDelorean is a library for clearing up the inconvenient truths \nthat arise dealing with datetimes in Python. \nnderstanding that timing is a delicate enough of a problem delorean hopes to provide a \ncleaner less troublesome solution to shifting, manipulating, generating datetimes.\nDelorean stands on the shoulders of giants pytz and dateutil.\nDelorean will provide natural language improvements for manipulating time,\nas well as datetime abstractions for ease of use. \nThe overall goal is to improve datetime manipulations, with a little bit of software and philosophy.\nPretty much make you a badass, time traveller.\n ",
138 | "delorean_exm": "\nfrom delorean import Delorean\n\nd = Delorean()\nd = d.shift('US/Eastern')\nreturn d\n ",
139 | "sh_dec": "\nsh is a full-fledged subprocess replacement for Python 2.6 - 3.8,\nPyPy and PyPy3 that allows you to call any program as if it were a function.\n ",
140 | "sh_exm": "\nfrom sh import tar\ntar(\"cvf\", \"/tmp/test.tar\", \"/my/home/directory/\")\n\n# resolves to \"curl http://duckduckgo.com/ -o page.html --silent\"\ncurl(\"http://duckduckgo.com/\", o=\"page.html\", silent=True)\n\n# or if you prefer not to use keyword arguments, this does the same thing:\ncurl(\"http://duckduckgo.com/\", \"-o\", \"page.html\", \"--silent\")\n\n# resolves to \"adduser amoffat --system --shell=/bin/bash --no-create-home\"\nadduser(\"amoffat\", system=True, shell=\"/bin/bash\", no_create_home=True)\n\n# or\nadduser(\"amoffat\", \"--system\", \"--shell\", \"/bin/bash\", \"--no-create-home\")\n ",
141 | "pymc_dec": "\nBayesian estimation, particularly using Markov chain Monte Carlo (MCMC), \nis an increasingly relevant approach to statistical estimation. \nHowever, few statistical software packages implement MCMC samplers, \nand they are non-trivial to code by hand. \npymc is a python package that implements the Metropolis-Hastings algorithm as a python class, \nand is extremely flexible and applicable to a large suite of problems. \npymc includes methods for summarizing output, plotting, goodness-of-fit and convergence diagnostics.\n*pymc only requires NumPy. All other dependencies such as matplotlib, SciPy, pytables, sqlite or mysql are optional.\n ",
142 | "pymc_exm": "\nfrom pymc import DiscreteUniform, Exponential, deterministic, Poisson, Uniform\nimport numpy as np\n\ndisasters_array = np.array([ 4, 5, 4, 0, 1, 4, 3, 4, 0, 6, 3, 3, 4, 0, 2, 6,\n 3, 3, 5, 4, 5, 3, 1, 4, 4, 1, 5, 5, 3, 4, 2, 5,\n 2, 2, 3, 4, 2, 1, 3, 2, 2, 1, 1, 1, 1, 3, 0, 0,\n 1, 0, 1, 1, 0, 0, 3, 1, 0, 3, 2, 2, 0, 1, 1, 1,\n 0, 1, 0, 1, 0, 0, 0, 2, 1, 0, 0, 0, 1, 1, 0, 2,\n 3, 3, 1, 1, 2, 1, 1, 1, 1, 2, 4, 2, 0, 0, 1, 4,\n 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1])\n\nswitchpoint = DiscreteUniform('switchpoint', lower=0, upper=110, doc='Switchpoint[year]')\nearly_mean = Exponential('early_mean', beta=1.)\nlate_mean = Exponential('late_mean', beta=1.)\n\n@deterministic(plot=False)\ndef rate(s=switchpoint, e=early_mean, l=late_mean):\n ''' Concatenate Poisson means '''\n out = np.empty(len(disasters_array))\n out[:s] = e\n out[s:] = l\n return out\n",
143 | "fuzzywuzzy_dec": "\nFuzzy string matching like a boss. It uses Levenshtein Distance to calculate the \ndifferences between sequences in a simple-to-use package.\n",
144 | "fuzzywuzzy_exm": "\n>>> from fuzzywuzzy import fuzz\n>>> from fuzzywuzzy import process\n>>> fuzz.ratio(\"this is a test\", \"this is a test!\")\n 97\n>>> fuzz.partial_ratio(\"this is a test\", \"this is a test!\")\n 100\n",
145 | "progressbar_dec": "\nA text progress bar is typically used to display the progress of a long running operation, \nproviding a visual cue that processing is underway.\nThe ProgressBar class manages the current progress, and the format of the \nline is given by a number of widgets. A widget is an object that may display \ndifferently depending on the state of the progress bar.\n",
146 | "progressbar_exm": "\nimport time\nimport progressbar\n\nwidgets=[\n ' [', progressbar.Timer(), '] ',\n progressbar.Bar(),\n ' (', progressbar.ETA(), ') ',\n]\nfor i in progressbar.progressbar(range(20), widgets=widgets):\n time.sleep(0.1)\n"
147 |
148 |
149 | },
150 |
151 | "what_is_python" : {
152 | "whs_py": "\nPython is an interpreted high-level general-purpose programming language. \nPython's design philosophy emphasizes code readability with its notable use of significant indentation. \nIts language constructs as well as its object-oriented approach aim to help programmers write clear, logical code for small and large-scale projects.\nPython is dynamically-typed and garbage-collected. \nIt supports multiple programming paradigms, including structured (particularly, procedural), object-oriented and functional programming. \nPython is often described as a \"batteries included\" language due to its comprehensive standard library.\nGuido van Rossum began working on Python in the late 1980s, as a successor to the ABC programming language, \nand first released it in 1991 as Python 0.9.0.\nPython 2.0 was released in 2000 and introduced new features, such as list comprehensions \nand a garbage collection system using reference counting and was discontinued with version 2.7.18 in 2020. \nPython 3.0 was released in 2008 and was a major revision of the language that is not completely backward-compatible \nand much Python 2 code does not run unmodified on Python 3.\nPython consistently ranks as one of the most popular programming languages.",
153 | "woh_wrote": "\nPython was conceived in the late 1980s by Guido van Rossum at Centrum Wiskunde & Informatica (CWI) \nin the Netherlands as a successor to ABC programming language, which was inspired by SETL, \ncapable of exception handling and interfacing with the Amoeba operating system. \nIts implementation began in December 1989. Van Rossum shouldered sole responsibility for the project, \nas the lead developer, until 12 July 2018, when he announced his \"permanent vacation\" from his responsibilities \nas Python's Benevolent Dictator For Life, a title the Python community bestowed upon him to reflect his long-term commitment as \nthe project's chief decision-maker. He now shares his leadership as a member of a five-person steering council. \nIn January 2019, active Python core developers elected Brett Cannon, Nick Coghlan, \nBarry Warsaw, Carol Willing and Van Rossum to a five-member \"Steering Council\" to lead the project.\nGuido van Rossum has since then withdrawn his nomination for the 2020 Steering council.\nPython 2.0 was released on 16 October 2000, with many major new features, \nincluding a cycle-detecting garbage collector and support for Unicode.\nPython 3.0 was released on 3 December 2008. It was a major revision of the language that is not completely backward-compatible.\nMany of its major features were backported to Python 2.6.x and 2.7.x version series. \nReleases of Python 3 include the 2to3 utility, which automates (at least partially) the translation of Python 2 code to Python 3.\nPython 2.7's end-of-life date was initially set at 2015 then postponed to 2020 out of concern \nthat a large body of existing code could not easily be forward-ported to Python 3.\nNo more security patches or other improvements will be released for it.\nWith Python 2's end-of-life, only Python 3.6.x and later are supported.\nPython 3.9.2 and 3.8.8 were expedited as all versions of Python (including 2.7) had security issues, \nleading to possible remote code execution and web cache poisoning.",
154 | "exm": "\nHello world program:\n\nprint('Hello, world!')\nProgram to calculate the factorial of a positive integer:\n\nn = int(input('Type a number, and its factorial will be printed: '))\n\nif n < 0:\n raise ValueError('You must enter a non negative integer')\n\nfactorial = 1\nfor i in range(2, n + 1):\n factorial *= i\n\nprint(factorial)"
155 | },
156 |
157 | "_comment": "Coded by AnonC0DER",
158 | "_comment" : "https://github.com/AnonC0DER/PyLe"
159 | }
--------------------------------------------------------------------------------