Skip to content

Instantly share code, notes, and snippets.

@sub-mod
sub-mod / tf_torch_proc_maps.md
Last active March 24, 2020 15:23
tf/pytorch proc maps
# cat /proc/12249/maps
00400000-00401000 r-xp 00000000 fd:03 1734922135                         /opt/rh/rh-python36/root/usr/bin/python3.6
00601000-00602000 r--p 00001000 fd:03 1734922135                         /opt/rh/rh-python36/root/usr/bin/python3.6
00602000-00603000 rw-p 00002000 fd:03 1734922135                         /opt/rh/rh-python36/root/usr/bin/python3.6
015fa000-175d0000 rw-p 00000000 00:00 0                                  [heap]
200000000-200200000 ---p 00000000 00:00 0
200200000-200400000 rw-s 00000000 00:06 35902                            /dev/nvidiactl
200400000-200600000 rw-s 00000000 00:06 35903                            /dev/nvidia0
200600000-203e00000 rw-s 00000000 00:06 35902                            /dev/nvidiactl
@sub-mod
sub-mod / Entitled_builds.md
Last active June 26, 2023 12:42
Entitled Builds on non-RHEL hosts
@sub-mod
sub-mod / OMP_NUM_THREADS.md
Created April 14, 2020 13:17
Use OMP_NUM_THREADS=1 for Running Pytorch on Openshift with 1CPU

Use OMP_NUM_THREADS=1 for Running Pytorch on Openshift with 1CPU
Else MKL will spawn threads for all the cpus it can see from the pod.

apiVersion: v1
kind: Template
metadata:
  name: playground
  labels:
    app: playground
@sub-mod
sub-mod / working_taskrun.yml
Created April 15, 2020 17:35
working taskrun
```---
apiVersion: tekton.dev/v1alpha1
kind: Task
metadata:
name: ic-buildah1
spec:
inputs:
params:
- name: BUILDER_IMAGE
description: The location of the buildah builder image.
@sub-mod
sub-mod / simple-bc.yml
Last active April 27, 2020 23:42
simple-buildConfig with Dockerbuild Strategy.
---
apiVersion: image.openshift.io/v1
kind: ImageStream
metadata:
name: test-bc-sample
spec:
lookupPolicy:
local: false
---
kind: "BuildConfig"
@sub-mod
sub-mod / buildah.yml
Created April 30, 2020 13:51
buildah.yml
---
apiVersion: tekton.dev/v1alpha1
kind: ClusterTask
metadata:
name: od-buildah
spec:
inputs:
params:
- name: BUILDER_IMAGE
description: The location of the buildah builder image.
@sub-mod
sub-mod / ruy.patch
Last active May 13, 2020 03:12
ruy.patch
diff --git a/tensorflow/lite/experimental/ruy/platform.h b/tensorflow/lite/experimental/ruy/platform.h
index 7a83173..36aaa95 100644
--- a/tensorflow/lite/experimental/ruy/platform.h
+++ b/tensorflow/lite/experimental/ruy/platform.h
@@ -55,7 +55,7 @@ limitations under the License.
// TODO(b/138433137) Select AVX-512 at runtime rather than via compile options.
#if defined(__AVX512F__) && defined(__AVX512DQ__) && defined(__AVX512CD__) && \
defined(__AVX512BW__) && defined(__AVX512VL__)
-#define RUY_DONOTUSEDIRECTLY_AVX512 1
+#define RUY_DONOTUSEDIRECTLY_AVX512 0
@sub-mod
sub-mod / openshift-pipelines-operator.md
Created July 3, 2020 02:36
Install openshift-pipelines-operator on OpenShift 4.4 using oc command

install openshift-pipelines-operator from CLI

Version: 1.0.1.

  • OpenShift-Pipelines: v0.11.3.
  • OpenShift-Pipelines-Triggers: v0.4.0.
  • OpenShift-Pipelines-ClusterTasks: v0.11.
$ oc get packagemanifests -n openshift-marketplace | grep pipeline
openshift-pipelines-operator                 Community Operators   32h
@sub-mod
sub-mod / Mac OS X: Open in Visual Studio Code
Created September 2, 2020 19:43 — forked from tonysneed/Mac OS X: Open in Visual Studio Code
Add a command to Finder services in Mac OSX to open a folder in VS Code
- Open Automator
- File -> New -> Service
- Change "Service Receives" to "files or folders" in "Finder"
- Add a "Run Shell Script" action
- Change "Pass input" to "as arguments"
- Paste the following in the shell script box: open -n -b "com.microsoft.VSCode" --args "$*"
- Save it as something like "Open in Visual Studio Code"