sandbox

dataflow module for data pipeline processing
proj_root
Path('/Users/x/devel/tspace')

source

foo

 foo ()

foo

assert foo()=="foo"
from fastcore.test import *
test_eq(foo(), "foo")
from IPython.display import display, SVG
display(SVG('<svg height="100" xmlns="http://www.w3.org/2000/svg"><circle cx="50" cy="50" r="40"/></svg> '))

show a graph with mermaid

flowchart LR
  A[Hard edge] --> B(Round edge)
  B --> C{Decision}
  C --> D[Result one]
  C --> E[Result two]

G run run intr intr run--intr kernel kernel run--kernel runbl runbl intr--runbl runbl--run zombie zombie kernel--zombie sleep sleep kernel--sleep runmem runmem kernel--runmem sleep--runmem swap swap sleep--swap runswap runswap swap--runswap runswap--runmem new new runswap--new new--runmem

sequenceDiagram
  participant Alice
  participant Bob
  Alice->>John: Hello John, how are you?
  loop Healthcheck
    John->>John: Fight against hypochondria
  end
  Note right of John: Rational thoughts <br/>prevail!
  John-->>Alice: Great!
  John->>Bob: How about you?
  Bob-->>John: Jolly good!


source

say_hi

 say_hi (to:str)

*Say hello to somebody

Args: to: somebody to say hello to*

Exported source
def say_hi(to: str):
    """
    Say hello to somebody


    Args:
        to: somebody to say hello to
    """

    return f"Hi {to}!"

source

say_hello

 say_hello (to:str)

Say hello to somebody

assert say_hello("Jeremy")=="Hello Jeremy!"
from fastcore.test import *
test_eq(say_hello("Jeremy"), "Hello Jeremy!")
from IPython.display import display, SVG
display(SVG('<svg height="100" xmlns="http://www.w3.org/2000/svg"><circle cx="50" cy="50" r="40"/></svg> '))

show a graph with mermaid

flowchart LR
  A[Hard edge] --> B(Round edge)
  B --> C{Decision}
  C --> D[Result one]
  C --> E[Result two]

G run run intr intr run--intr kernel kernel run--kernel runbl runbl intr--runbl runbl--run zombie zombie kernel--zombie sleep sleep kernel--sleep runmem runmem kernel--runmem sleep--runmem swap swap sleep--swap runswap runswap swap--runswap runswap--runmem new new runswap--new new--runmem

sequenceDiagram
  participant Alice
  participant Bob
  Alice->>John: Hello John, how are you?
  loop Healthcheck
    John->>John: Fight against hypochondria
  end
  Note right of John: Rational thoughts <br/>prevail!
  John-->>Alice: Great!
  John->>Bob: How about you?
  Bob-->>John: Jolly good!

add a class


source

HelloSayer

 HelloSayer (to)

Say hello to to using say_hello


source

HelloSayer.say

 HelloSayer.say ()

Do the saying

o = HelloSayer("Alexis")
o.say()
'Hello Alexis!'
draw_n(3)
[1, 2, 3]

source

draw_n

 draw_n (n:int, replace:bool=True)

Draw n cards.

Type Default Details
n int
replace bool True Number of cards to draw # Draw with replacement?
Returns list List of cards

source

draw_np

 draw_np (n:int, replace:bool=True)

Draw n cards.

Type Default Details
n int Number of cards to draw
replace bool True Draw with replacement?
Returns list List of cards

source

MP

 MP (timestep:pandas._libs.tslibs.timestamps.Timestamp, velocity:float,
     thrust:float, brake:float, current:float, voltage:float)

Motion power tuple

add math

\[\sum_{i=1}^{k+1}i\]