This file contains hidden or 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 json | |
import torch | |
from typing import Dict | |
from pathlib import Path | |
def retry_me(max_retries): | |
def decorator(func): | |
def wrapper(*args, **kwargs): | |
last_err = None |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or 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 builtins | |
import sys | |
class Packagify: | |
""" | |
Used to load python projects that aren't suitable to be used as packages | |
You can use this class as following: | |
``` | |
from packagify import Packagify |
This file contains hidden or 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
#!/usr/bin/python | |
import copy | |
import torch | |
import numpy as np | |
torch.manual_seed(0) | |
class Original(torch.nn.Module): |
This file contains hidden or 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 { isNetworkRequestInFlight } from 'apollo-client/core/networkStatus'; | |
/** | |
* Hooking into the onBroadcast function to save the inFlight data point in the client state | |
*/ | |
apolloClient.queryManager.onBroadcast = () => { | |
const { queryManager: { queryStore: { store } } } = apolloClient; | |
const queries = Object.values(store); | |
// if we can find a way to escape early that will be better, but regular for loops don't sit well with eslint | |
const inFlight = queries.reduce( |
This file contains hidden or 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>HTML5 Canvas Gamma Adjust</title> | |
<meta name="og:title" content="HTML5 Canvas Gamma Adjust"/> | |
<meta name="author" content="Rijul Gupta"> | |
<meta name="description" content="An implementation of Gamma filter in HTML5 Canvas"/> | |
</head> |
This file contains hidden or 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
-- --------------------------------------------------------------------. | |
-- | |
-- Example VHDL Component Organization | |
-- | |
-- Title : example | |
-- : | |
-- Library : work | |
-- : | |
-- Developers : Rijul Gupta ([email protected]) | |
-- : |