Skip to content

Instantly share code, notes, and snippets.

@InJeCTrL
InJeCTrL / Parser.java
Last active June 20, 2020 11:47
TextParser&Print
import java.io.*;
import java.util.*;
public class Parser{
class info{
String time;
long n_Bytes;
String filename;
public info(String a, long b, String c){
time = a;
@InJeCTrL
InJeCTrL / HYeasy_monitor.py
Last active July 26, 2020 02:49
虎牙简单直播监控
import urllib.parse
import urllib.request
import argparse
import bs4
import json
import time
import base64
argParser = argparse.ArgumentParser()
argParser.description = 'For learning use only, DO NOT use it for illegal purposes. Please indicate the origin, if you use it to record and upload the video to any platform. -- InJeCTrL'
@InJeCTrL
InJeCTrL / masscan_json_parser.py
Created April 20, 2020 04:41
masscan_json_parser
import json
import urllib.parse
import urllib.request
import pandas as pd
import numpy as np
def fetchURLresponse(URL, data = None):
while True:
try:
response = urllib.request.urlopen(urllib.request.Request(URL, data = data), timeout = 5)
@InJeCTrL
InJeCTrL / YZBeasy_monitor.py
Last active July 2, 2020 03:46
一直播简单直播监控
import urllib.parse
import urllib.request
import argparse
import bs4
import json
import time
argParser = argparse.ArgumentParser()
argParser.description = 'For learning use only, DO NOT use it for illegal purposes. Please indicate the origin, if you use it to record and upload the video to any platform. -- InJeCTrL'
argParser.add_argument("memberId", help = "MemberId of target performer")
@InJeCTrL
InJeCTrL / getAV.js
Created March 24, 2020 06:05
获取B站BV号对应AV号
function getAV(BVID){
$.ajax({
type: "GET",
url: "https://api.bilibili.com/x/web-interface/view",
data: {bvid: BVID},
success: function(ret){
console.log(ret.data.aid);
}
})
}
@InJeCTrL
InJeCTrL / m3u8Downloader.py
Last active May 26, 2021 20:17
m3u8视频分段下载&合并
from concurrent.futures import ThreadPoolExecutor, wait, ALL_COMPLETED
from Crypto.Cipher import AES
import threading
import requests
import os
class m3u8_downloader:
'''
m3u8下载类
'''
@InJeCTrL
InJeCTrL / Getshow3Data.php
Created March 17, 2020 07:23
一种分层级显示散点图
<?php
error_reporting(E_ALL || ~E_NOTICE);
include "../conn/conn.php";
if (isset($_REQUEST['lwtype']))
{
$Herb_ID = $_REQUEST['lwtype'];
}
if (isset($_REQUEST['OB']))
{
$OB = $_REQUEST['OB'];
@InJeCTrL
InJeCTrL / VideoPlay.html
Created March 9, 2020 17:26
视频在线预览
<html>
<head>
<title>篮哩篮哩-RIP</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
</head>
<style>
@media not screen and (min-width : 768px) {
#video{width: 100%;object-fit: fill;}
}
@InJeCTrL
InJeCTrL / Call.php
Last active February 7, 2020 16:40
PHP操作Mysql导入导出Excel数据
<?php
require_once 'ExcelFuncs.php';
$testconn = mysqli_connect('127.0.0.1', 'root', '123', 'db_office');
$testconn->set_charset('utf8');
/*
// 测试导出
$test = new ExportTable($testconn);
$test->AddExportTbl('lunwen', 'lwid', array(1, 2, 3), array('lwid', 'lwpublish'));
$test->AddExportTbl('lunwen_member', 'lm_lwid', array(1, 2, 3), array('lm_id', 'lm_lwid', 'lm_wid', 'lm_member', 'lm_sequence', 'lm_name', 'tongxun'));
$test->Download('测试导出');
@InJeCTrL
InJeCTrL / deal.py
Last active December 29, 2019 04:01
上证50成分股逐窗口协方差计算
import numpy as np
import pandas as pd
import os
def CalcCovList(code_stock, tbl_IH, tbl_stock, W = 20, n = 1, Unit = 1):
'''
W: 窗口大小(每个窗口包含的分钟数)
n: 期货行情比成分股行情延后的分钟数
Unit: 窗口每次滑动的行数
Return: 时间-协方差数据框