Skip to content

Instantly share code, notes, and snippets.

View highoncarbs's full-sized avatar
🏠
Working from home

Padam Sethia highoncarbs

🏠
Working from home
View GitHub Profile
@highoncarbs
highoncarbs / gist:9edc2279d3b35960795c4bc03ceee7f9
Created March 26, 2017 09:14
Log of pocketsphinx speech recognition session
INFO: pocketsphinx.c(152): Parsed model-specific feature parameters from /usr/local/share/pocketsphinx/model/en-us/en-us/feat.params
Current configuration:
[NAME] [DEFLT] [VALUE]
-agc none none
-agcthresh 2.0 2.000000e+00
-allphone
-allphone_ci no no
-alpha 0.97 9.700000e-01
-ascale 20.0 2.000000e+01
-aw 1 1
@highoncarbs
highoncarbs / gist:345b738fe21539fc1427e66bc53b6e25
Created March 31, 2017 12:09
Session Log running ros_voice_control.py by Arseniy Gorin
ALSA lib pcm_route.c:867:(find_matching_chmap) Found no matching channel map
connect(2) call to /dev/shm/jack-0/default/jack_0 failed (err=No such file or directory)
attempt to connect to server failed
INFO: pocketsphinx.c(152): Parsed model-specific feature parameters from /usr/local/lib/python2.7/dist-packages/pocketsphinx/model/en-us//feat.params
Current configuration:
[NAME] [DEFLT] [VALUE]
-agc none none
-agcthresh 2.0 2.000000e+00
-allphone
-allphone_ci no no
@highoncarbs
highoncarbs / Lex.c
Last active January 17, 2018 08:58
Lexical Analyzer for C Language
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#include<ctype.h>
int isKeyword(char buffer[]){
char keywords[32][10] = {"auto","break","case","char","const","continue","default",
"do","double","else","enum","extern","float","for","goto",
"if","int","long","register","return","short","signed",
"sizeof","static","struct","switch","typedef","union",
#!/usr/bin/python
import sys
def breakdown(filename, chunk):
lines = []
line_counter = 0
file_counter = 0
with open(filename) as file:
def nearly_equal(str1, str2):
m, n = len(str1) + 1, len(str2) + 1
string_table = {}
for i in range(m):
string_table[i, 0] = i
for j in range(n):
string_table[0, j] = j
@highoncarbs
highoncarbs / index.vue
Created July 12, 2022 12:46
Index.vue
<template>
<div class="">
<div>
<div class="hero-img">
<img class="plant_one" src="~assets/indigoplant-line.png" alt="" />
<img class="plant_two" src="~assets/indigoplant-line.png" alt="" />
<!-- <img class="pattern_left" src="~assets/pattern_three.png" alt="" />
<img class="pattern_right" src="~assets/pattern_one.png" alt="" /> -->
</div>
<section class="section pb-6 bg-pattern has-background-bagru-red">
@highoncarbs
highoncarbs / index.vue
Created March 3, 2023 09:31
Index template for route /products - https://jaiteart-web.web.app
<template>
<div>
<div class="section ">
<div class="columns is-vcentered is-centered" >
<div class="column is-5 ">
<div class="px-6 has-text-centered">
<h2 class="
title
serif
@highoncarbs
highoncarbs / formula_builder.vue
Created September 20, 2023 06:12
Code for Formula Builder
<template>
<div class="container">
<p class="is-size-5 has-text-weight-semibold">Formula Builder</p>
<br />
<!-- Entry Form -->
<div class="">
<div class="">
<div class="">
let formula = "";
for root rules array :
formula = [ first ] [ operator ] [ if second_value_type == 'value' then [ second] else [ second (master )] ]
for (rule,index) in rules.rules:
let rule_level_one = [ rule.first ] [ rule.operator ] [ if rule.second_value_type == 'value' then [ rule.second] else [ rule.second (master )] ] // Will be truth or false
if rule_level_one:
for sub_rule in rule.rules:
let sub_rule_temp = [ sub_rule.first ] [ sub_rule.operator ] [ if sub_rule.second_value_type == 'value' then [ sub_rule.second] else [ sub_rule.second (master )] ]
<template>
<div class="container">
<p class="is-size-5 has-text-weight-semibold">Formula Builder</p>
<br />
<!-- Entry Form -->
<div class="">
<div class="">
<div class="">