| context | shortcut | action |
|---|---|---|
| desktop | ctrl + super + ←/→ | switch to desktop left/right |
| shift + super + ←/→ | move active window to display left/right | |
| super + tab | show virtual desktops | |
| ctrl + super + D | create new virtual desktop | |
| browsing | ctrl + shift + L | auto-fill username and password with Bitwarden |
| ctrl + shift + M | switch Chrome profile |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| black | |
| ipywidgets | |
| isort | |
| jedi-language-server | |
| jupyterlab | |
| jupyterlab_pygments | |
| jupyterlab_rise | |
| pygments |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| poetry run python -m ipykernel install --user --name pymedphys |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Google Fonts | |
| @import url(http://fonts.googleapis.com/css?family=Zilla+Slab|Zilla+Slab+Highlight|Inter|Fira+Code:400italic,700italic,400,700); | |
| // Font Variables | |
| $zilla-slab: "Zilla Slab", serif; | |
| $zilla-slab-highlight: "Zilla Slab Highlight", serif; | |
| $inter: "Inter", sans-serif; | |
| $fira-code: "Fira Code"; | |
| // Colours |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: python-data-science | |
| channels: | |
| - conda-forge | |
| dependencies: | |
| - python=3.10 | |
| - adlfs | |
| - altair==5.0.1 | |
| - black | |
| - ipykernel | |
| - matplotlib |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| FROM python:3.6-alpine | |
| # Opted for alpine to get a lean docker image as possible | |
| RUN apk add --no-cache openssl | |
| ENV DOCKERIZE_VERSION v0.6.1 | |
| RUN wget https://github.com/jwilder/dockerize/releases/download/$DOCKERIZE_VERSION/dockerize-alpine-linux-amd64-$DOCKERIZE_VERSION.tar.gz \ | |
| && tar -C /usr/local/bin -xzvf dockerize-alpine-linux-amd64-$DOCKERIZE_VERSION.tar.gz \ | |
| && rm dockerize-alpine-linux-amd64-$DOCKERIZE_VERSION.tar.gz | |
| # Python deps for alpine |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from zeep import Client | |
| client = Client("https://webservices.cibg.nl/Ribiz/OpenbaarV4.asmx?wsdl") | |
| client.service.ListHcpApprox4(WebSite="Ribiz", Name="Kerkhoven", Initials="M") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def sparse_matrix_to_tensor(X): | |
| """Transforms SciPy sparse matrix to tensorflow.sparse.SparseTensor.""" | |
| row_nnz = np.diff(X.indptr) | |
| indices = np.asarray([[row_i, col_i] | |
| for row_i, nnz in enumerate(row_nnz) | |
| for col_i in range(nnz)], dtype=np.int64) | |
| values = X.data | |
| return SparseTensor(indices=indices, values=values, dense_shape=X.shape) |
- install Windows Terminal
- install wsl
- install Ubuntu
sudo apt update && sudo apt upgrade- install Homebrew
- install pyenv
- Issue with ctypes module: pyenv/pyenv#1933
- install oh-my-posh
- install jump
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def make_polynomial(dataframe, degree=MAX_DEGREE): | |
| """Function for creating higher-order polynomial features from dataframe. | |
| Dataframe df should be like [Y, X1, X2, .. Xi]. | |
| Returns dataframe polynomial features of X1 ... Xi up to degree polynomials.""" | |
| df = dataframe.copy() | |
| cols = df.columns[1:] | |
| for i in range(2, degree + 1): | |
| for col in cols: |