[Gem-web][gem-web] is a tool that capable of providing an interface that allows opening documentation, source code, and website of a ruby gem. My goal on GSoC was integrating it on RubyGems' CLI, which would make this feature available out of the box to all ruby users, improving their productivity, since there would have no need to search this information manually.
import torch as th | |
""" | |
Author: Josue N Rivera (github.com/wzjoriv) | |
Date: 7/3/2021 | |
Description: Snippet of various clustering implementations only using PyTorch | |
Full project repository: https://github.com/wzjoriv/Lign (A graph deep learning framework that works alongside PyTorch) | |
""" | |
def random_sample(tensor, k): |
# | |
# Taken from https://www.gadgetdaily.xyz/create-a-cool-sliding-and-scrollable-mobile-menu/ | |
# | |
# Convert value returned from Linux event device ("evdev") to a HID code. This | |
# is reverse of what's actually hardcoded in the kernel. | |
# | |
# Lubomir Rintel <lkundrak@v3.sk> | |
# License: GPL | |
# | |
# Ported to a Python module by Liam Fraser. |
To have Bundler report anonymous usage metrics over HTTP to rubygems.org when a heavy command is run (to avoid deteriorating the runtime), and to have a backend API endpoint in rubygems.org to instrument it.
Basically, yes. The actual implementation changed a little bit, and we decided to only instrument the low cardinality metrics using Datadog, as the free Datadog version limits value cardinality and wouldn't work with, for example, time related metrics.
#!/bin/bash | |
for a in $(ls -1 access* | sort -t. -k3,3nr) | |
do | |
cat "$a" >> combined_access.log | |
done | |
for e in $(ls -1 error* | sort -t. -k3,3nr) | |
do | |
cat "$e" >> combined_error.log |
from pyspark.sql.functions import * | |
# Implementation of ANOVA function: calculates the degrees of freedom, F-value, eta squared and omega squared values. | |
# Expects that 'categoryData' with two columns, the first being the categorical independent variable and the second being the scale dependent variable | |
def getAnovaStats(categoryData) : | |
cat_val = categoryData.toDF("cat","value") | |
cat_val.createOrReplaceTempView("df") | |
newdf = spark.sql("select A.cat, A.value, cast((A.value * A.value) as double) as valueSq, ((A.value - B.avg) * (A.value - B.avg)) as diffSq from df A join (select cat, avg(value) as avg from df group by cat) B where A.cat = B.cat") | |
grouped = newdf.groupBy("cat") |
#!/bin/bash | |
# This script will create you CA-signed client certificate. | |
# | |
# First, please follow these steps: | |
# - Create the root pair | |
# - Create the intermediate pair | |
# in https://jamielinux.com/docs/openssl-certificate-authority/ | |
# | |
# Second, this script will NOT use attributes defined in your | |
# `openssl.cnf'. Define your C, ST, and O to the head of this |
# After Ubuntu 16.04, Systemd becomes the default. | |
# It is simpler than https://gist.github.com/Doowon/38910829898a6624ce4ed554f082c4dd | |
[Unit] | |
Description=Jupyter Notebook | |
[Service] | |
Type=simple | |
PIDFile=/run/jupyter.pid | |
ExecStart=/home/phil/Enthought/Canopy_64bit/User/bin/jupyter-notebook --config=/home/phil/.jupyter/jupyter_notebook_config.py |
#!/bin/bash | |
# Batch change the mode bit (the permission of files and directories) | |
# | |
# USAGE: script_name [path1] [path2]... | |
# script_name | |
# | |
# Author: Jongmin Kim (kdzlvaids@gmail.com) | |
No, seriously, don't. You're probably reading this because you've asked what VPN service to use, and this is the answer.
Note: The content in this post does not apply to using VPN for their intended purpose; that is, as a virtual private (internal) network. It only applies to using it as a glorified proxy, which is what every third-party "VPN provider" does.
- A Russian translation of this article can be found here, contributed by Timur Demin.
- A Turkish translation can be found here, contributed by agyild.
- There's also this article about VPN services, which is honestly better written (and has more cat pictures!) than my article.