refer to https://code.visualstudio.com/docs/editor/userdefinedsnippets for installation
on my machine the file goes in %appdata%\Code\User\snippets
axism
: Signals for AXI-Stream Master
axismgen
: Generics for AXI-Stream Master
% this file is part of my wordle solver | |
% https://github.com/valerionew/wordle-solver | |
% almost all data from a reddit thread | |
% | |
close all | |
clear | |
robot = [1, 122, 554, 588, 209, 42, 6]; | |
robot = robot./sum(robot).*100; % normaliz | |
human(1,:) = [1, 14, 62, 117, 43, 18, 0]; |
refer to https://code.visualstudio.com/docs/editor/userdefinedsnippets for installation
on my machine the file goes in %appdata%\Code\User\snippets
axism
: Signals for AXI-Stream Master
axismgen
: Generics for AXI-Stream Master
#!/usr/bin/python3 | |
""" | |
Copyright 2021 Mygod | |
Licensed under the Apache License, Version 2.0 (the "License"); | |
you may not use this file except in compliance with the License. | |
You may obtain a copy of the License at | |
http://www.apache.org/licenses/LICENSE-2.0 |
So here's the story: a friend of mine wanted to share on the web some notes he wrote in OneNote. The PDF was 155 pages and weighted 270MB. This was exceeding the 100MB max file size limit of the service we were using.
After doing some research on the internet, i discovered this was pretty common for OneNote files, in particular if you have active the pressure sensitivity. Searching the internet did not produce any result, so after a day of research i finally got a method working that reduce the 278MB file into a 24MB file, with no significant loss.
The key to this process is the rasterization, where we transform the nicely-indefinitely-zoomable vector traces into a picture of the page, and put the picture in the PDF page instead of the vector notes. You loose the flexibility of having a vector based PDF, but you can compress a PDF much more.
<?php | |
/** | |
* Plugin Name: [Forminator Pro] - Add "autcomplete" attribute to input fields | |
* Plugin URI: https://premium.wpmudev.org/ | |
* Description: Add "autcomplete" attribute support to selected form and input fields (as of 1.12.1.1) | |
* Author: Alessandro Kaounas @ WPMUDEV | |
* Author URI: https://premium.wpmudev.org/ | |
* Task: 0/1135022585412927/1176249490871345 | |
* License: GPLv2 or later | |
*/ |
% IN -----UUUUU---\/\/\/----+----------+-- OUT | |
% L R1 | | | |
% \ _|_ | |
% R2 / ___ C | |
% \ | | |
% _|_ _|_ | |
% \ / \ / | |
format longe; | |
close all; | |
clear all; |
/* | |
Generatore di onda quadra a 1MHz per Arduino Uno, basato su timer1 | |
Valerio Nappi - 04-04-2020 | |
Impostiamo di seguito il timer1 di arduino (sul quale fa affidamento la libreria servo, | |
quindi rompendo la compatibilità con quella libreria). | |
Il timer1 è un contatore a 16 bit che conserva il suo valore nel registro TCNT1 (Time CouNnT timer1). | |
Lo impostiamo in modo che una volta raggiunta una certa soglia (conservata in OCR1A - Output Compare Register timer1 channel A) | |
inverta il valore logico del pin speciale OC1A (Output Compare timer1 channel A), mappato sul pin 9 di arduino. |
#include <avr/interrupt.h> // cli | |
int main (void) { | |
char oldsreg = SREG; // save the interrupt setting register to oldsreg | |
cli(); // disable all the interrupts (SREG = 0) | |
CCP = 0xD8; // signature to CCP | |
CLKMSR = 0; // use clock 00: Calibrated Internal 8 MHzOscillator | |
CCP = 0xD8; // signature | |
CLKPSR = 0; // set prescaler to :1 (0x00) | |
SREG = oldsreg; // restore the sreg, enabling the interrupts |
Risultato | Frequenza osservata | Frequenza teorica | Chi-quadro | |
---|---|---|---|---|
1 | 170 | 166.6667 | 0.06667 | |
2 | 154 | 166.6667 | 0.96265 | |
3 | 171 | 166.6667 | 0.11267 | |
4 | 174 | 166.6667 | 0.32267 | |
5 | 154 | 166.6667 | 0.96265 | |
6 | 177 | 166.6667 | 0.64068 | |
TOTALE | 1000 | 1000 | 3.068 |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <stdint.h> | |
int main(int argc, char const *argv[]) { | |
FILE * lettura = fopen("campionetesto.txt", "r"); | |
if ( lettura == NULL ) | |
return -1; |