Mix.install([
{:vega_lite, "~> 0.1.6"},
{:kino, "~> 0.8.1"},
{:kino_vega_lite, "~> 0.1.7"},
{:explorer, "~> 0.5.6"},
This file contains 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 ghcr.io/livebook-dev/livebook:latest-cuda11.8 | |
ENV LIVEBOOK_APP_SERVICE_NAME "🐳 Hugging Face - $SPACE_TITLE" | |
ENV LIVEBOOK_APP_SERVICE_URL "https://huggingface.co/spaces/$SPACE_AUTHOR_NAME/$SPACE_REPO_NAME" | |
ENV LIVEBOOK_UPDATE_INSTRUCTIONS_URL "https://livebook.dev" | |
ENV LIVEBOOK_WITHIN_IFRAME "true" | |
ENV LIVEBOOK_APPS_PATH "/public-apps" | |
ENV LIVEBOOK_DATA_PATH "/data" | |
ENV LIVEBOOK_PORT 7860 |
This file contains 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
# elixir ./slow_model_run.ex | |
# Title: Debugging: slowness 2nd model execution after binding variable | |
Mix.install( | |
[ | |
{:exla, "~> 0.4"}, | |
{:nx, "~> 0.4"}, | |
{:axon, "~> 0.4.1"} | |
], |
This file contains 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
# eprof_results is the output printed by the `eprof` profiler | |
# with the "extra" lines already stripped (e.g. "Profile done over XXX matching functions") | |
eprof_results | |
|> String.split("\n", trim: true) | |
|> Enum.map(fn | |
"anonymous fn" <> _rest = row -> | |
[anonymous_fn, rest] = | |
String.split(row, ~r{anonymous fn/\d+ in .*/\d+}, trim: true, include_captures: true) | |
[anonymous_fn] ++ String.split(rest, ~r/\s/, trim: true) |
This file contains 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
12:27:55.731 [debug] Axon.Loop started initializing loop state | |
12:27:55.733 [debug] EXLA defn evaluation #Function<135.40305314/2 in Nx.Defn.Compiler.fun/2> cache miss in 2.1ms | |
12:27:55.992 [debug] EXLA compilation #Function<135.40305314/2 in Nx.Defn.Compiler.fun/2> cache miss in 258.2ms | |
12:27:55.992 [debug] EXLA device 0 lock in 0.0ms | |
12:27:55.992 [debug] EXLA execution on device 0 in 0.2ms | |
12:27:55.992 [debug] Axon.Loop finished initializing loop state in 260.8ms | |
12:27:55.992 [debug] Axon.Loop started running epoch 0 | |
12:27:55.993 [debug] Axon.Loop started batch step execution | |
12:27:55.993 [debug] EXLA defn evaluation #Function<2.47039548/4 in Axon.Loop.build_batch_fn/2> cache miss in 0.8ms | |
12:27:56.170 [debug] EXLA compilation #Function<2.47039548/4 in Axon.Loop.build_batch_fn/2> cache miss in 176.5ms |
This file contains 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
<!-- livebook:{"persist_outputs":true} --> | |
# Random Normal - issue with defn | |
## Section | |
```elixir | |
Mix.install([ | |
{:exla, "~> 0.1.0-dev", github: "elixir-nx/nx", sparse: "exla"}, | |
{:nx, "~> 0.1.0-dev", github: "elixir-nx/nx", sparse: "nx", override: true} |
The purpose of design is to allow you to do design later, and it's primary goal is to reduce the cost of change.
- Single Responsibility Principle: a class should have only a single responsibility
- Open-Closed Principle: Software entities should be open for extension, but closed for modification (inherit instead of modifying existing classes).
- Liskov Substitution: Objects in a program should be replaceable with instances of their subtypes without altering the correctness of that program.
- Interface Segregation: Many client-specific interfaces are better than one general-purpose interface.
This file contains 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
// Standard user configurations | |
{ | |
"auto_complete": true, | |
"auto_complete_commit_on_tab": true, | |
"binary_file_patterns": | |
[ | |
"*.jpg", | |
"*.jpeg", | |
"*.png", | |
"*.gif", |
This file contains 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
# v1.0 | |
# November 21, 2015 | |
FROM jenkins:latest | |
MAINTAINER NickGnd "[email protected]" | |
# https://github.com/jenkinsci/docker/blob/4fa9ebc13069fa8186728622cd63702cddf11162/Dockerfile | |
ENV RUBY_VERSION 2.2.3 | |
# --handlerCountStartup = set the no of worker threads to spawn at startup. Default is 5 |