pythagoras 0.23.17__py3-none-any.whl → 0.23.18__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: pythagoras
3
- Version: 0.23.17
3
+ Version: 0.23.18
4
4
  Summary: Planet-scale distributed computing in Python.
5
5
  Keywords: cloud,ML,AI,serverless,distributed,parallel,machine-learning,deep-learning,pythagoras
6
6
  Author: Volodymyr (Vlad) Pavlov
@@ -113,15 +113,13 @@ Decorating a function:
113
113
  @pure()
114
114
  def my_long_running_function(a:float, b:float) -> float:
115
115
  from time import sleep # imports must be placed inside a pure function
116
- for i in range(5):
117
- sleep(1)
118
- print("waiting....")
116
+ sleep(5)
119
117
  return a+10*b
120
118
  ```
121
119
 
122
120
  Using a decorated function synchronously:
123
121
  ```python
124
- result = my_long_running_function(a=1, b=2)
122
+ result = my_long_running_function(a=1, b=2) # only named arguments are allowed
125
123
  ```
126
124
 
127
125
  Using a decorated function asynchronously:
@@ -139,11 +137,7 @@ Pre-conditions for executing a function:
139
137
  unused_cpu(cores=10)])
140
138
  def my_long_running_function(a:float, b:float) -> float:
141
139
  from time import sleep
142
- for i in range(5):
143
- sleep(1)
144
- print(
145
- "waiting...."
146
- )
140
+ sleep(5)
147
141
  return a+10*b
148
142
  ```
149
143
 
@@ -154,7 +148,7 @@ def factorial(n:int)->int:
154
148
  if n == 1:
155
149
  return 1
156
150
  else:
157
- return n*factorial(n=n-1)
151
+ return n*factorial(n=n-1) # only named arguments are allowed
158
152
  ```
159
153
 
160
154
  Partial function application:
@@ -60,6 +60,6 @@ pythagoras/_900_project_stats_collector/__init__.py,sha256=Eagt-BhPPtBGgpMywx2lk
60
60
  pythagoras/_900_project_stats_collector/project_analyzer.py,sha256=uhycFKjUIXEpYcZYnak3yn4JFhchl-oZ7wt6spFxhoY,3574
61
61
  pythagoras/__init__.py,sha256=TMPtJdSi_WShCpJnsVVdO48Wcvs78GMbUi5gHc1eMLw,1233
62
62
  pythagoras/core/__init__.py,sha256=cXtQ-Vbm8TqzazvkFws5cV3AEEYbEKzNXYeuHeLGFK0,328
63
- pythagoras-0.23.17.dist-info/WHEEL,sha256=NHRAbdxxzyL9K3IO2LjmlNqKSyPZnKv2BD16YYVKo18,79
64
- pythagoras-0.23.17.dist-info/METADATA,sha256=b3mlrM4fFVErDphFSruQ8SyKvSs7jsss6fgTQ7CW6ek,7605
65
- pythagoras-0.23.17.dist-info/RECORD,,
63
+ pythagoras-0.23.18.dist-info/WHEEL,sha256=NHRAbdxxzyL9K3IO2LjmlNqKSyPZnKv2BD16YYVKo18,79
64
+ pythagoras-0.23.18.dist-info/METADATA,sha256=3s7ztGkAceirTtK1EBxxPuKy_BGYGK7d24mN0gHXzJo,7561
65
+ pythagoras-0.23.18.dist-info/RECORD,,