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
''' | |
python test.py recipes/tinyllama_mole/sft/config_routeraux_ep3.yaml | |
''' | |
import logging | |
import random | |
import sys | |
import datasets | |
import torch |
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 cv2 | |
import numpy as np | |
import trimesh | |
import os | |
import glob | |
from PIL import Image | |
from colmap_utils import qvec2rotmat, rotmat2qvec, read_images_binary, read_cameras_text, read_images_text | |
def load_K_Rt_from_P(P): |
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
This is the detailed profiling: | |
``` | |
Execute Stats: | |
Execute Stat 1 | |
Number of HVX threads used : 4 count | |
RPC (execute) time : 2717302 us | |
QNN accelerator (execute) time : 2714698 us | |
Num times yield occured : 0 count |
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
@inproceedings{karras2020analyzing, | |
title={Analyzing and improving the image quality of stylegan}, | |
author={Karras, Tero and Laine, Samuli and Aittala, Miika and Hellsten, Janne and Lehtinen, Jaakko and Aila, Timo}, | |
booktitle={Proceedings of the IEEE/CVF conference on computer vision and pattern recognition}, | |
pages={8110--8119}, | |
year={2020} | |
} | |
@article{radford2019language, | |
title={Language models are unsupervised multitask learners}, |
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 | |
from srt.encoder import SRTEncoder | |
from srt.decoder import SRTDecoder, NerfDecoder | |
import yaml | |
batch_size = 1 | |
num_views = 2 | |
device = torch.device("cuda:0") |
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
# https://github.com/lucidrains/vit-pytorch/blob/main/vit_pytorch/vit_pytorch.py | |
import torch | |
import torch.nn.functional as F | |
from einops import rearrange | |
from torch import nn | |
from torch.nn.modules.utils import _pair | |
MIN_NUM_PATCHES = 16 |
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 os | |
import torch | |
import h5py as h5 | |
from torchvision import datasets | |
from tqdm import tqdm | |
""" | |
Usage: this script creates `imagenet_train.h5` in `data_path`. | |
If you need to create `imagenet_val.h5`, set `is_train = False` at L26. |
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 copy | |
from typing import Optional, List | |
from dotmap import DotMap | |
import torch | |
import torch.nn.functional as F | |
from torch import nn, Tensor | |
from asteroid_filterbanks import make_enc_dec |
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
#!/usr/bin/env python | |
# coding: utf-8 | |
import numpy as np | |
import random | |
from PIL import Image | |
import matplotlib.pyplot as plt | |
import torch#!/usr/bin/env python | |
# coding: utf-8 | |
import numpy as np |
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 os | |
import time | |
import math | |
import itertools | |
import numpy as np | |
from PIL import Image | |
from tqdm import tqdm | |
from copy import deepcopy | |
import torch |
NewerOlder