- See available modules:
module spider
- See available versions of a module:
module spider <name>
- Load specified version of the module:
module load <name>/<version>
Step 0: Install Bazel 3.7.2:
You could build from source. But there was an issue with openjdk
that I just didn't bother to look into.
pamac install bazel3-bin
Step 1: Install CUDA and cuDNN. You can find the exact versions TensorFlow supports here here. As of the time of writing this report, if you've installed proprietary drivers when installing the OS, you'll have to run the following commands in Manjaro:
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
import asyncio | |
import collections | |
class Trigger: | |
"""Asynchronous synchronization primitive for triggering groups of tasks. | |
The class borrows much of its implementation from `asyncio.Event`. However, it gets rid of the internal flag, so | |
that whenever another coroutine waits on it, it can only be awakened with an explicit "new" call to `set()`. If | |
another waits on the task in a loop, one call to `set()` let's it run for a single iteration. |
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
#!/bin/bash | |
TEXT_RESET='\e[0m' | |
TEXT_YELLOW='\e[1;33m' | |
wget https://developer.nvidia.com/compute/cuda/9.2/Prod2/local_installers/cuda-repo-ubuntu1604-9-2-local_9.2.148-1_amd64 | |
echo -e $TEXT_YELLOW | |
echo 'WEBGET finished..' | |
echo -e $TEXT_RESET |
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
import torch | |
class StandardScaler: | |
def __init__(self, mean=None, std=None, epsilon=1e-7): | |
"""Standard Scaler. | |
The class can be used to normalize PyTorch Tensors using native functions. The module does not expect the | |
tensors to be of any specific shape; as long as the features are the last dimension in the tensor, the module |
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
import numpy as np | |
import matplotlib.pyplot as plt | |
# Store your values inside the 'values' variable as a iteratable (i.e. list) | |
# I'll just use some random numbers instead | |
values = np.random.normal(size=10000) | |
# The line below renders the chart and saves it to memory | |
# 50 is the number of bins, density scales the chart so the area under the graph would be 1, the other two are just some appearance controls | |
n, bins, patches = plt.hist(values, 50, density=True, facecolor='g', alpha=0.75) |