cug_coffee
码龄9年
关注
提问 私信
  • 博客:39,610
    社区:1
    39,611
    总访问量
  • 66
    原创
  • 947,924
    排名
  • 0
    粉丝
  • 0
    铁粉
IP属地以运营商信息为准,境内显示到省(区、市),境外显示到国家(地区)
IP 属地:广东省
  • 加入CSDN时间: 2016-05-18
博客简介:

cug_coffee的博客

查看详细资料
个人成就
  • 获得7次点赞
  • 内容获得3次评论
  • 获得18次收藏
创作历程
  • 1篇
    2023年
  • 20篇
    2020年
  • 9篇
    2019年
  • 11篇
    2018年
  • 25篇
    2017年
  • 2篇
    2016年
成就勋章
TA的专栏
  • 语音识别
    7篇
  • leet_code
    3篇
  • 基础学习-C++
    32篇
  • 深度学习笔记
    1篇
  • 脚本
    3篇
  • c++基础
    12篇
  • 标准库stl
    5篇
  • makefile
    2篇
  • python基础
    5篇
  • mac入门
    3篇
兴趣领域 设置
  • 音视频
    语音识别
创作活动更多

如何做好一份技术文档?

无论你是技术大神还是初涉此领域的新手,都欢迎分享你的宝贵经验、独到见解与创新方法,为技术传播之路点亮明灯!

357人参与 去创作
  • 最近
  • 文章
  • 代码仓
  • 资源
  • 问答
  • 帖子
  • 视频
  • 课程
  • 关注/订阅/互动
  • 收藏
搜TA的内容
搜索 取消

cpp固定位数输出

cc 固定位数输出
原创
发布博客 2023.11.21 ·
103 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

leetcode-300

leetcode 300 连续增长子序列的个数,典型的动态规划 #include <iostream> #include <cstdio> #include <algorithm> #include <string> int lengthOfLIS(std::vector<int>& nums) { int len = nums.size(); int res = len; std::vector<int> seq
原创
发布博客 2020.11.18 ·
157 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

leetcode-213

直接上代码了。 最典型的动态规划,写出动态规划的方程就好。 这里分两种情况, 0号位选取时,0号位不选取时,len<=3时特殊处理。 f[i] = f[i-2] > f[i-3] ? f[i-2]+a[i] : f[i-3]+a[i]; #include <iostream> #include <cstdio> #include <algorithm> #include <string> #include <vector> int
原创
发布博客 2020.11.18 ·
126 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

bazel编译与类的继承

在类的继承里面,会涉及到虚函数的问题,我现在先贴一下正确的代码如下。 #ifndef _TEST_CLASS_H #define _TEST_CLASS_H class Base { public: virtual ~Base(); virtual void Print(); }; class Derive : public Base { public: virtual ~Derive(); virtual void Print(); }; #endif //TEST_CLASS
原创
发布博客 2020.09.22 ·
173 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

c++ memory pool 内存池

这里就直接贴上代码了,基本高效实现。 template<class T> class MemoryPool { public: T* Malloc() { if (free_element_ == last_element_) { return nullptr; } T* result = reinterpret_cast<T *>(free_element_); free_element_ = free_element_->n
原创
发布博客 2020.09.05 ·
361 阅读 ·
0 点赞 ·
0 评论 ·
1 收藏

获取时间

这里就直接贴上代码了,获取某一段程序运行的时间。 #include <iostream> #include <cstdio> #include <cstdlib> #include <algorithm> #include <string> #include <sys/time.h> #include <unistd.h> #define USDIFF(new, old) (1000000 * (int64_t)((new
原创
发布博客 2020.08.19 ·
116 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

最大子数组的和

这里就直接上代码了,非常简单的一个代码了,动态规划 #include <iostream> #include <cstdio> // using namespace std; int main() { int arr[] = {-1, 5, -4, 7, 3, -2, -1, 4, -6}; int len = sizeof(arr)/sizeof(int); int sum_val = 0; int start_index = 0; int end_index
原创
发布博客 2020.06.02 ·
187 阅读 ·
0 点赞 ·
0 评论 ·
1 收藏

单例模式

这里直接上代码了 #include <iostream> #include <cstdio> #include <algorithm> #include <string> #include <memory> #include <mutex> class Singleton{ public: typedef std::shared_ptr<Singleton> Ptr; ~Singleton(){
原创
发布博客 2020.05.08 ·
142 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

python的string类型与dictionary

将字符串转为dictionary data_str = ''' {'start_time': '0', 'end_time': '70', 'text': '明天天气'} ''' 对于上面的字符串,可以直接用 info_map = eval(data_str) print('start:%s, end:%s' % (info_map['start_time'], info_map['end_ti...
原创
发布博客 2020.04.14 ·
344 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

python多线程互斥锁问题

之前一直觉得python的多线程有点问题,今天搞了一下多线程的事情;直接上代码了。 #-*- coding:utf8 -*- #!/usr/bin/env python import os import sys import subprocess import json import string import re import time from threading import Threa...
原创
发布博客 2020.03.27 ·
267 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

高斯混合模型

高斯混合模型,首先说的那就是高斯分布, f(x)=12πσexp⁡(−(x−μ)22σ2)=N(x,σ,μ2) f(x)=\frac{1}{\sqrt{{2\pi}}\sigma}\exp(-\frac{(x-\mu)^2}{2\sigma^2})=N(x,\sigma,\mu^2) f(x)=2π​σ1​exp(−2σ2(x−μ)2​)=N(x,σ,μ2) 对应的均值方差是μ\muμ,σ2\si...
原创
发布博客 2020.03.16 ·
325 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

最大似然估计

现在简单写写最大似然估计。 最大似然估计是一个概率估计问题,譬如已知一个数据空间XXX,数据XXX中的每一个样本都有n为特征。有样本整体x=[x1,x2,x3,x4,.....,xn]x=[x_1,x_2,x_3,x_4,.....,x_n]x=[x1​,x2​,x3​,x4​,.....,xn​]。同时了有这样的先验知识,知道数据空间XXX里面所有的样本,都符合一个的概率密度函数(prob de...
原创
发布博客 2020.03.16 ·
369 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

python中文单字问题

一直都有这个问题的说,或许其实并没有自己想象的那么难处理的说; 对应的python2 python3都有相应的解决办法。 已知有文件 明天天气 现在需要进行单字切分,得到文件 明 天 天 气 python2 与 python3 都有相应的解决办法,现在直接贴代码了 python2 #!/usr/bin/env python #coding:utf-8 import os import sy...
原创
发布博客 2020.03.12 ·
272 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

fst-graph

这里就直接贴上代码了。 digraph G { node [shape = circle] 0 -> 1 [ label = sil ] 0 -> 2 [ label = w ] 1 -> 1 [ label = sil ] 1 -> 2 [ label = w ] 2 -> 2 [ label = w ] 2 -> 3 [ labe...
原创
发布博客 2020.03.05 ·
465 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

构图逻辑

现在写写一般的构图逻辑,这里会介绍ci-phone的,同时也会介绍cd-phone的构图逻辑。 一般介绍 ci-phone构图 cd-phone构图 下面先介绍下技术背景,主要应用在解码过程中,也就是语音识别;譬如唤醒、命令词都可以应用。对于一个词的发音序列 word : phn1 phn2 phn3 word: A B C D E ... Z 其中A就是词头,Z就是词尾。 先介绍ci-p...
原创
发布博客 2020.03.05 ·
477 阅读 ·
1 点赞 ·
0 评论 ·
0 收藏

c++一次性读取文件

c++中一次读取整个文件的内容的方法: 读取至char*的情况 std::ifstream t; int length; t.open("file.txt"); // open input file t.seekg(0, std::ios::end); // go to the end length = t.tellg(); // report ...
原创
发布博客 2020.03.04 ·
1137 阅读 ·
1 点赞 ·
0 评论 ·
4 收藏

语音识别--gmm-hmm思考

简单回顾一下今天所看的内容: gmm-hmm pdf: 概率密度函数,在这里可以由gmm来估计,同样也可以用dnn来估计。 gmm: 高斯混合模型,单高斯函数,多高斯函数。 能拟合任何函数,这里会涉及到均值方差等变量 语音有短时平稳的特性,可以用高斯混合模型来估计;从而就会有概率密度函数。 hmm:隐马尔科夫模型,双马尔科夫链的过程。关键在于理解状态。 首先需要的说的马尔科夫链。当与时间无关时,...
原创
发布博客 2020.03.01 ·
437 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

语音识别-先验概率后验概率似然函数

这里贴一个网页: https://www.cnblogs.com/wjgaas/p/4523779.html 简单的说: Posterior probability ∝ Likelihood × Prior probability 从语音识别的角度来看这个问题,那么就是,解码的过程就是求取后验概率的过程。 ref_W = argmax_w(p(O|W) * P(W)/P(O)) 已知观察...
原创
发布博客 2020.03.01 ·
1265 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

语音识别Topo笔记

这里记录一下语音识别中的拓扑的问题。 三因子状态的topo Chain-model的topo Ctc的topo 三因子状态的topo <Topology> <TopologyEntry> <ForPhones> 1 2 3 4 5 6 7 8 </ForPhones> <State> 0 <PdfClass> 0 <...
原创
发布博客 2020.03.01 ·
225 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏

dot图-有限状态机

dot图的规则跟语法,先来看一个最简单的例子。 digraph g { label=test 深圳 -> 南山 [ label = "process"] 南山 -> 科技园 南山 -> 金融公司 { rank=same 科技园 金融公司 } } 转成png的linux命令行是 dot -Tpng ./test.dot -o test.png 参考文献,见如下网页,非...
原创
发布博客 2020.02.29 ·
903 阅读 ·
0 点赞 ·
0 评论 ·
0 收藏
加载更多