➜ openssl dgst -sha256 openssl-1.1.1.tar.gz
SHA256(openssl-1.1.1.tar.gz)= 2836875a0f89c03d0fdf483941512613a50cfb421d6fd94b9f41d7279d586a3d
➜ cat openssl-1.1.1.tar.gz.sha256
2836875a0f89c03d0fdf483941512613a50cfb421d6fd94b9f41d7279d586a3d
| import torch | |
| from torch import nn | |
| from torch.autograd import Variable | |
| import torch.nn.functional as F | |
| import torch.optim as optim | |
| # toy feed-forward net | |
| class Net(nn.Module): | |
| def __init__(self): |
| class UnionFind: | |
| """Weighted quick-union with path compression and connected components. | |
| The original Java implementation is introduced at | |
| https://www.cs.princeton.edu/~rs/AlgsDS07/01UnionFind.pdf | |
| >>> uf = UnionFind(10) | |
| >>> for (p, q) in [(3, 4), (4, 9), (8, 0), (2, 3), (5, 6), (5, 9), | |
| ... (7, 3), (4, 8), (6, 1)]: | |
| ... uf.union(p, q) |
➜ openssl dgst -sha256 openssl-1.1.1.tar.gz
SHA256(openssl-1.1.1.tar.gz)= 2836875a0f89c03d0fdf483941512613a50cfb421d6fd94b9f41d7279d586a3d
➜ cat openssl-1.1.1.tar.gz.sha256
2836875a0f89c03d0fdf483941512613a50cfb421d6fd94b9f41d7279d586a3d
| /** | |
| The MIT License (MIT) | |
| Copyright (c) 2017 Fredrik Westmark | |
| Permission is hereby granted, free of charge, to any person obtaining a copy | |
| of this software and associated documentation files (the "Software"), to deal | |
| in the Software without restriction, including without limitation the rights | |
| to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
| copies of the Software, and to permit persons to whom the Software is |
| /** | |
| * Example to refresh tokens using https://github.com/auth0/node-jsonwebtoken | |
| * It was requested to be introduced at as part of the jsonwebtoken library, | |
| * since we feel it does not add too much value but it will add code to mantain | |
| * we won't include it. | |
| * | |
| * I create this gist just to help those who want to auto-refresh JWTs. | |
| */ | |
| const jwt = require('jsonwebtoken'); |
| """ | |
| In jupyter notebook simple logging to console | |
| """ | |
| import logging | |
| import sys | |
| logging.basicConfig(stream=sys.stdout, level=logging.INFO) | |
| # Test | |
| logger = logging.getLogger('LOGGER_NAME') |
Follow these steps to remove all archives from an AWS vault. After this is finished, you will be able to delete the vault itself through the browser console.
This will create a job that collects required information about the vault.
$ aws glacier initiate-job --job-parameters '{"Type": "inventory-retrieval"}' --account-id YOUR_ACCOUNT_ID --region YOUR_REGION --vault-name YOUR_VAULT_NAME
| import argparse | |
| import sys | |
| import tempfile | |
| from time import time | |
| import random | |
| from os import listdir | |
| from os.path import isfile, join | |
| import pandas |
npm update -g updates all global packages and their dependencies, see npm/npm#6247.