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 time | |
import textwrap | |
from flask import Flask, render_template, Response, jsonify | |
class Progress: | |
''' | |
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js" /> | |
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css" /> |
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 collections | |
import json | |
import pathlib | |
import re | |
import requests | |
import tqdm | |
from bs4 import BeautifulSoup | |
from fuzzywuzzy import fuzz |
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 asyncio | |
from graia.broadcast import Broadcast | |
from graia.application import GraiaMiraiApplication, Session | |
from graia.application.event.mirai import NewFriendRequestEvent | |
from graia.application.message.chain import MessageChain | |
from graia.application.message.elements.internal import Plain, At, Source, Image | |
from graia.application.friend import Friend | |
from graia.application.group import Group, Member | |
from graia.application.interrupts import GroupMessageInterrupt |
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 functools | |
import inspect | |
import pathlib | |
import pickle | |
import time | |
from pynput import keyboard | |
from pynput.keyboard import Key, KeyCode, Controller | |
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 datetime | |
import pathlib | |
import pickle | |
import matplotlib.pyplot as plt | |
import pandas as pd | |
import seaborn as sns | |
directory = pathlib.Path('data') |
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 collections | |
import json | |
import os | |
import pathlib | |
import re | |
class tex: | |
@classmethod | |
def commands(cls, content): |
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
# -*- encode: utf-8 -*- | |
from collections.abc import Callable | |
def SUSTech(grade:int) -> float: | |
data = [ | |
[ 0, 59, 0.00], | |
[60, 62, 1.15], | |
[63, 66, 1.63], | |
[67, 69, 2.08], |
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 fitz | |
import os | |
import pathlib | |
import pdf2image | |
import shutil | |
import subprocess | |
import tempfile | |
from typing import Callable, Iterator, List, Union |
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://sikouhjw.gitee.io/2021/02/14/2021-02-14-fontset-overleaf/ | |
% https://www.overleaf.com/latex/templates/using-the-ctex-package-on-overleaf-zai-overleafping-tai-shang-shi-yong-ctex/gndvpvsmjcqx | |
% https://zhuanlan.zhihu.com/p/145429470 | |
\GetIdInfo$Id: ctex.dtx 81d4c90 2020-10-19 20:24:58 +0800 Qing Lee <[email protected]> $ | |
{SUSTech fonts definition (CTEX)} | |
\ProvidesExplFile{ctex-fontset-sustech.def} | |
{\ExplFileDate}{2.5.5}{\ExplFileDescription} | |
\RequirePackage{xpatch} | |
\xpatchcmd \fontspec_new_script:nn | |
{ \__fontspec_warning:nxx } |
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
#![feature(proc_macro_span)] | |
extern crate proc_macro; | |
use proc_macro::TokenStream; | |
use std::cmp::Ordering::{Greater, Less, Equal}; | |
#[proc_macro] | |
pub fn python(tokens: TokenStream) -> TokenStream { | |
let mut lines: Vec<String> = source_code(tokens) |