自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(40)
  • 收藏
  • 关注

原创 GAMES101-作业2

static bool insideTriangle(double x, double y, const Vector3f* _v){ // TODO : Implement this function to check if the point (x, y) is inside the triangle represented by _v[0], _v[1], _v[2] Eigen::Vector2f p; p << x, y; Eigen::Vector2f AB

2022-01-24 19:51:15 537

原创 GAMES101-作业1

Eigen::Matrix4f get_model_matrix(float rotation_angle){ Eigen::Matrix4f model = Eigen::Matrix4f::Identity(); // TODO: Implement this function // Create the model matrix for rotating the triangle around the Z axis. // Then return it. r

2022-01-24 12:53:18 164

原创 GAMES101-作业0

#include<cmath>#include<eigen3/Eigen/Core>#include<eigen3/Eigen/Dense>#include<iostream>int main(){ // Basic Example of cpp std::cout << "Example of cpp \n"; float a = 1.0, b = 2.0; std::cout << a &

2022-01-21 15:57:43 656

原创 计算机网络自顶向下-套接字编程作业

作业1:Web服务器# WebServer.py# import socket module from concurrent.futures import threadfrom socket import * import sys # In order to terminate the program import threadingdef webProcess(connectionSocket): try: message = connectionSocket.

2022-01-21 15:38:55 2077

原创 Visual Studio安装修改共享文件夹路径

打开注册表:win+R,输入regedit,确定打开此目录:计算机\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\Setup删除SharedInstallationPath文件

2021-10-23 19:05:55 1277

原创 操作系统导论OSTEP 第39章作业答案 插叙:文件和目录

问题1#include <stdio.h>#include <sys/stat.h>int main(int argc, char **argv){ if(argc < 2) return 0; struct stat st; stat(argv[1], &st); printf("inode: %d\n", (int)st.st_ino); printf("hard link: %d\n", (int)st.st_nlink); printf("

2021-09-06 21:08:29 296

原创 操作系统导论OSTEP 第38章作业答案 廉价冗余磁盘阵列(RAID)

问题1linux.> ./raid.py -R 20 -n 5 -L 5 -s 1 -5 LS -cARG blockSize 4096ARG seed 1ARG numDisks 4ARG chunkSize 4kARG numRequests 5ARG reqSize 4kARG workload randARG writeFrac 0ARG randRange 20ARG level 5ARG raid5 LSARG reverse FalseARG timing F

2021-09-02 14:48:42 611

原创 操作系统导论OSTEP 第28章作业答案 锁

问题4生成不同的中断频率,运行结果会不同,仍然存在竞态。问题5程序test-and-set.s.var mutex.var count.main.top .acquire # 获取锁mov $1, %ax xchg %ax, mutex # atomic swap of 1 and mutextest $0, %ax # if we get 0 back: lock is free!jne .acquire # if not

2021-08-26 16:21:38 1202

原创 操作系统导论OSTEP 第26章作业答案 并发:介绍

问题1程序loop.s:.main.topsub $1,%dxtest $0,%dx jgte .top halt执行结果:linux.> ./x86.py -p loop.s -t 1 -i 100 -R dx -c dx Thread 0 0 -1 1000 sub $1,%dx -1 1001 test $0,%dx -1 1002 jgte .top -

2021-08-25 11:13:12 879 1

原创 PAT、蓝桥杯 最短路径总结

文章目录PAT浙江大学-数据结构-2019夏 **07-图6** **旅游规划** (25分) [Dijikstra算法]浙江大学-数据结构-2019夏 08-图7 公路村村通 (30分) [Prim算法]A**1003** **Emergency** **(25分)**A1018 Public Bike Management (30分)A1030 Travel Plan (30分)A1087 All Roads Lead to Rome (30分) [Dijkstra算法 + DFS,最短路径]A1111

2021-08-24 20:17:18 619 1

原创 PAT、蓝桥杯、LeetCode二叉树总结

复习的时候找到了以前的笔记。。感觉还记得挺详细的。。发出来方便以后查阅~文章目录PATA1004 Counting Leaves (30分) [BFS, DFS, 数的层序遍历]A1020 Tree Traversals (25分) [二叉树的遍历,后序中序转层序]A1053 Path of Equal Weight (30分) [树的遍历]A1079 Total Sales of Supply Chain (25分) [DFS, BFS, 树的遍历]A1086 Tree Traversals Again

2021-08-24 20:09:55 590

原创 操作系统导论OSTEP-第19章作业答案 分页:快速地址转换(TLB)

文章目录第19章 分页:快速地址转换(TLB)问题1:问题2:问题3:问题4:问题5:问题6:问题7:第19章 分页:快速地址转换(TLB)问题1:man gettimeofday查看gettimeofday如何使用:精度微秒。问题2:查看页大小:linux.> getconf PAGE_SIZE4096本题代码:#include <stdio.h>#include <sys/time.h>#include <stdlib.h>#inc

2021-08-23 11:50:23 551

原创 CSAPP3.0-BombLab

此实验是CSAPP3.0的第二个实验,原理可参考书中第三章。此实验需要通过6关以及一个隐藏关,闯关失败会引爆炸弹。phase_1使用gdb bomb命令打开调试器反汇编phase_1:其功能是比较输入字符串和0x402400位置处的字符串。查看0x402400位置处的字符串:可知phase_1输入字符串为:Border relations with Canada have never been better.运行:phase_2反汇编phase_2:Dump of assemble

2021-07-29 16:08:15 340

原创 CSAPP3.0-CacheLab

Part A:编写缓存模拟器b (block bits) 不需要模拟使用LRU策略使用verbose输出详细信息(hit, miss, eviction)便于调试I指令忽略L、S指令执行单步HitMissEviction(缓存加载)M指令执行两步HitMissEviction(缓存加载)getopt的使用方法:fscanf的用法使用的库函数#include "cachelab.h"#include <stdio.h> // fopen#include &

2021-07-24 20:00:20 258

原创 CSAPP3.0-AttackLab

Part 1: Code Injection Attacks/* getbuf code */unsigned getbuf(){ char buf[BUFFER_SIZE]; Gets(buf); return 1;}/* test code */void test(){ int val; val = getbuf(); printf("No exploit. Getbuf returned 0x%x\n", val);}Level

2021-07-24 19:35:54 186

原创 CSAPP 3.0-Data Lab

CSAPP Lab官网CUM Intro to Computer Systems课程官网本文是对CSAPP3.0实验一Data Lab的实验记录,主要参考了这篇文章:https://zhuanlan.zhihu.com/p/59534845?utm_source=qq题目列表题解bitXor“异或”是两数不同则为1,相同则为0。故返回1时,两数不能同时为0,也不能同时为1:~(~x&~y)&~(x&y),也可以表达为x=0,y=1或y=0,x=1:(~x&y)|

2021-03-07 15:52:38 294

原创 顶层const

顶层const(top-level const)顶层 const 可以表示任意的对象是常量。这一点对任何数据类型都适用,如算术类型、类、指针等。int i = 0;int *const p1 = &i; // 若对象为指针,则靠右的 const 是顶层 constconst int ci = 42; // 除了指针之外的其他类型,const 只能写在左边,// 并且是顶层 const。低层const(low-level const)任何常量引用都是低层 const。对于指针来说,靠左

2020-06-27 20:45:35 1673

原创 词嵌入、词向量

先存起来,方便自己复习hhhhh~词嵌入:https://machinelearningmastery.com/what-are-word-embeddings/Keras词嵌入模型:https://machinelearningmastery.com/use-word-embedding-layers-deep-learning-keras/邱锡鹏-面向自然语言处理的分布式表示学习:https://www.bilibili.com/video/av28262903词向量:https://w

2020-06-09 13:23:46 502

原创 图像语义分割数据集

Pascal voc 2012 数据集简介COCO数据集的简介Cityscapes数据集的简介

2020-05-05 15:37:11 599

转载 从头到尾彻底理解KMP

https://blog.csdn.net/v_july_v/article/details/7041827

2020-04-21 22:10:33 171

原创 Python中if __name__ == ‘__main__‘的用法

阅读文献时经常看到if __name__ == '__main__'这个东东,那么,它到底是用来干事神马的呢?创建两个文件a.py、b.pya.py:a = 'a'def main(): print(a)main()运行,输出了a。b.py:b = 'b'def main(): print(b)main()运行,输出了b。在b文件前面引入a文件:imp...

2020-03-04 17:49:21 145

原创 Python中filter过滤器

要想取出list中的偶数,你是不是想到了使用for循环?不过这次,我们使用filter函数来做测试:a = [1,2,3,4,5,6,7,8,9,10]a = filter(lambda x: x % 2 == 0, a)print(list(a))输出:[2, 4, 6, 8, 10]代码是不是更加简洁了呢O(∩_∩)O~...

2020-03-04 17:48:09 62

原创 周周练 | 第九届真题解析

第九届软件A/B/C组的第一、二题链接:周周练 | 第九届真题解析题目1:分数1/1 + 1/2 + 1/4 + 1/8 + 1/16 + …每项是前一项的一半,如果一共有20项,求这个和是多少,结果用分数表示出来。类似:3/2当然,这只是加了前2项而已。分子分母要求互质。注意:需要提交的是已经约分过的分数,中间任何位置不能含有空格。请不要填写任何多余的文字或符号。此...

2020-03-04 17:47:26 122

原创 Multi-Scale Context Aggregation by Dilation Convolutions

翻译笔记kerastensorflow

2020-02-04 14:19:25 46

原创 deeplab

DeepLab v2DeepLab v3 and PSPNetDeepLab v3+DeepLab合集(只测试了v1、v2没有测试v3、v3+)

2020-01-30 22:41:28 68

原创 图像分割综述

图像分割技术介绍最全综述 | 图像分割算法

2020-01-07 15:19:04 31

原创 多特征融合

深度特征融合—高低层特征融合模式分类中的特征融合方法以及各种方法的总结

2020-01-04 19:18:48 453

原创 linux配置双拼

sudo apt-get install fcitx-pinyinfcitx-config-gtk3进入配置后,选择附加组件,拼音基本设置,选择双拼之后点击右上角的拼音,进去选择双拼

2019-11-25 15:54:12 329

原创 Batch-Normalization

【AI数学】Batch-Normalization详细解析Batch Normalization 详解 李宏毅我们希望μ\muμ和σ\sigmaσ代表train set整体的statistic。但是,实际上,统计train set整体的statistic是很耗费时间的,并且每一层parameters的数值是不断在改变的。所以我们要在batch里边算normalization,这意味着你的bat...

2019-11-24 19:41:51 75

原创 Python中*args, *kwargs的用法

*args可以实现传入多个,但又不确定几个的形参定义。实参传入后python将其组织成元组(tuple)。**kwargs可以实现传入多个,但又不确定几个的键值对定义,实参传入后python将其组织成字典(dict)。Example:input:def main(arg, *args, **kwargs): print(arg) print(args) prin...

2019-10-10 09:05:15 111

原创 莫烦python-pytorch-3.5批数据训练

import torchimport torch.utils.data as DataBATCH_SIZE = 10x = torch.linspace(1, 10, 10)y = torch.linspace(10, 1, 10)torch_dataset = Data.TensorDataset(x, y)loader = Data.DataLoader( ...

2019-10-07 20:03:41 180

原创 莫烦python-pytorch-3.4保存提取

保存、读取模型保存模型def save(): # save net1 net1 = torch.nn.Sequential( torch.nn.Linear(1, 10), torch.nn.ReLU(), torch.nn.Linear(10, 1), ) optimizer = torch.optim.SGD(...

2019-10-07 19:26:31 72

原创 莫烦python-pytorch-3.2classification

建立数据集import torchfrom torch.autograd import Variableimport torch.nn.functional as Fimport matplotlib.pyplot as pltn_data = torch.ones(100, 2)x0 = torch.normal(2*n_data, 1) # 1是标准差,normal返回的是第一个...

2019-10-07 17:38:03 116

原创 莫烦python-pytorch-3.1regression

import torchfrom torch.autograd import Variableimport torch.nn.functional as Fimport matplotlib.pyplot as pltx = torch.unsqueeze(torch.linspace(-1, 1, 100), dim=1) # 二维y = x.pow(2) + 0.2*torch....

2019-10-07 16:28:49 122

原创 LeetCode-454. 4Sum II

题目描述Given four lists A, B, C, D of integer values, compute how many tuples (i, j, k, l) there are such that A[i] + B[j] + C[k] + D[l] is zero.To make problem a bit easier, all A, B, C, D have same l...

2019-10-01 22:01:18 64

原创 LeetCode-3. Longest Substring Without Repeating Characters

题目描述Given a string, find the length of the longest substring without repeating characters.Example 1:Input: “abcabcbb”Output: 3Explanation: The answer is “abc”, with the length of 3.Example 2...

2019-10-01 13:24:32 64

原创 LeetCode-415. Add Strings (Easy)

Given two non-negative integers num1 and num2 represented as string, return the sum of num1 and num2.Note:The length of both num1 and num2 is < 5100.Both num1 and num2 contains only digits 0-9....

2019-09-29 22:51:25 56

原创 LeetCode-989. Add to Array-Form of Integer (Easy)

题目描述For a non-negative integer X, the array-form of X is an array of its digits in left to right order. For example, if X = 1231, then the array form is [1,2,3,1].Given the array-form A of a non-ne...

2019-09-29 21:17:30 73

原创 LeetCode-67. Add Binary (Easy)

题目描述Given two binary strings, return their sum (also a binary string).The input strings are both non-empty and contains only characters 1 or 0.Example 1:Input:a = “11”, b = “1”Output:“100”Ex...

2019-09-29 20:33:19 62

原创 LeetCode-2.Add Two Numbers (Medium)

题目描述You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order and each of their nodes contain a single digit. Add the two numbers and ret...

2019-09-29 20:14:00 65

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除