View hubspot_func.js
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
hbspt.forms.create({ | |
region: "na1", | |
portalId: "19646847", | |
formId: "dcc34642-805c-4d18-890f-6d8a74d000cf" | |
}); |
View schema_drop.sql
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
SET FOREIGN_KEY_CHECKS = 0; | |
SET SESSION group_concat_max_len = 1000000; | |
SET @TABLES = NULL; | |
SELECT GROUP_CONCAT('`', table_schema, '`.`', table_name,'`') INTO @TABLES FROM information_schema.tables | |
WHERE table_schema = 'databaseName'; | |
SET @TABLES = CONCAT('DROP TABLE IF EXISTS ', @TABLES); | |
PREPARE stmt FROM @TABLES; |
View nginx.conf
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
GNU nano 4.8 metabase.com # sample nginx.conf | |
# proxy requests to Metabase instance | |
server { | |
listen 80; | |
listen [::]:80; | |
listen 443 ssl; # managed by Certbot | |
ssl_certificate /etc/letsencrypt/live/metabase.covidindiaresources.com/fullchain.pem; | |
ssl_certificate_key /etc/letsencrypt/live/metabase.covidindiaresources.com/privkey.pem; |
View gist:14f879193e91aeac1ff7d8b775943db7
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 { ajax } from 'rxjs/ajax'; | |
// action creators | |
const fetchUser = username => ({ type: FETCH_USER, payload: username }); | |
const fetchUserFulfilled = payload => ({ type: FETCH_USER_FULFILLED, payload }); | |
// epic | |
const fetchUserEpic = action$ => action$.pipe( | |
ofType(FETCH_USER), | |
mergeMap(action => |
View arduino_counter.ino
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
int count=0; | |
void setup() | |
{ | |
Serial.begin(9600); | |
} | |
void loop() | |
{ | |
while(1) |
View publisher.py
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 paho.mqtt.publish as publish | |
publish.single("bv_solutions/test", "payload", hostname="mqtt.eclipse.org") |
View ff_serialiser.py
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 subprocess as sp | |
import cv2 as cv | |
import numpy as np | |
import ffmpeg | |
probe = ffmpeg.probe('/home/jyotendra/Videos/pandas.mp4') | |
video_info = next(s for s in probe['streams'] if s['codec_type'] == 'video') | |
width = int(video_info['width']) | |
height = int(video_info['height']) | |
num_frames = int(video_info['nb_frames']) |
View string_splitter_printer.py
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
# | diving 42.6% | accident 79.7% | collapsing 79.9% | |
def splitter(text, threshold): | |
text = text.strip() | |
text = text.split("|") | |
new_text_array = [] | |
for txt in text: | |
txt = txt.strip() | |
if txt == '': | |
continue |
View annotations_corrector.py
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 glob, os | |
import argparse | |
import xml.etree.ElementTree as ET | |
import ntpath | |
parser = argparse.ArgumentParser() | |
parser.add_argument("-i", "--images", required=True, help="enter path where images are stored") | |
parser.add_argument("-l", "--labels", required=True, help="enter path where labels are stored") |
View settings.json
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
{ | |
"licenser.license": "Custom", | |
"licenser.author": "Jyotendra Sharma", | |
"licenser.projectName": "SignalRApp", | |
"licenser.useSingleLineStyle": false, | |
"licenser.customHeader": "@FILE@ - @PROJECT@\r\nCopyright @YEAR@ - Bitvivid Solutions Pvt. Ltd. \r\n*********************************************************\r\nAuthor - @AUTHOR@ \r\n*********************************************************\r\nNo part of this software may be copied or distributed without written consent from Bitvivid Solutions Pvt. Ltd (company).\r\nThe company holds right to prosecute the individual\/organisation\/company found guilty of misusing company's intellectual properties." | |
} |
NewerOlder