介绍不同分词器的文章不少,较经典的有BosonNLP 11款开放中文分词引擎大比拼
可惜这11款分词器只有IK和结巴一直在更新elastic的分词器插件,Boson的插件已经很久没更新
所以加上elastic自带的smartcn 也就只有三种分词器可选。
注1:smartcn基于中科院的ictclas 但用的是1.0, 似乎没再更新
package main | |
import ( | |
"fmt" | |
"io" | |
"log" | |
"net/http" | |
"os" | |
) |
介绍不同分词器的文章不少,较经典的有BosonNLP 11款开放中文分词引擎大比拼
可惜这11款分词器只有IK和结巴一直在更新elastic的分词器插件,Boson的插件已经很久没更新
所以加上elastic自带的smartcn 也就只有三种分词器可选。
注1:smartcn基于中科院的ictclas 但用的是1.0, 似乎没再更新
use std::io::prelude::*; | |
use std::process::{Command, Stdio}; | |
fn main() { | |
let mut child = Command::new("ffmpeg") | |
// Overwrite file if it already exists | |
.arg("-y") | |
// Interpret the information from stdin as "raw video" ... | |
.arg("-f") | |
.arg("rawvideo") |
--[[ | |
Prevent the screen from blanking while a video is playing. | |
This script is a workaround for the GNOME+Wayland issue documented in the | |
[Disabling Screensaver] section of the mpv manual, and depends on | |
gnome-session-inhibit (usually provided by the gnome-session package) to set up | |
the inhibitors. | |
#!/bin/sh | |
# ref https://unix.stackexchange.com/a/457902 | |
journalctl --rotate | |
journalctl --vacuum-time=1s |
First, install arch-install-scripts:
sudo pacman -S --needed arch-install-scripts
Secondly, mount your partitions in all the internal hard drives.
Thirdly, generate and validate your config by piping it out to stdout:
[ Update 2020-05-31: I won't be maintaining this page or responding to comments anymore. The list of supporting software reflects the known state as of this date. ]
Most of the terminal emulators auto-detect when a URL appears onscreen and allow to conveniently open them (e.g. via Ctrl+click or Cmd+click, or the right click menu).
It was, however, not possible until now for arbitrary text to point to URLs, just as on webpages.
Ctrl + Alt + Space
// Compile with e.g. `gcc -o /tmp/eatmem /tmp/eatmem.c` | |
#include <errno.h> | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <unistd.h> | |
#define DEFAULT_SLEEP_SECONDS 600 | |
#define DEFAULT_ALLOC_MB 1024 |
#!/bin/sh | |
# create a podman container with fifo named pipe as log file | |
# for demonstrate issue https://github.com/containers/podman/issues/13081 | |
CTR_NAME="redis-demo" | |
function print_title() { | |
title=$1 | |
echo "" | |
echo "|=================== $title ===================>>>" |