Ubuntu下安装snap包

我想在Ubuntu上用Mathpix Snipping Tool,官网上提示在Ubuntu中用以下命令安装.

sudo snap install mathpix-snipping-tool

但是一直卡在如下命令.

Download snap "core" (6673) from channel "stable"

于是去这个第三方平台下了mathpix-snipping-tool.snap文件,想直接安装.snap文件.又报错.

snap install mathpix-snipping-tool.snap

error: cannot find signatures with metadata for snap "mathpix-snipping-tool.snap"

在这个论坛中,说是要

snap ack snipping-tool.assert

但是我在第三方平台中只能下.snap包,没有.assert文件.

If you don’t care about the assertion, you can run snap install --dangerous , but then you won’t receive updates.

但是可以用 --dangerous参数.不管更新.

snap install --dangerous mathpix-snipping-tool.snap

半小时后,终于安装好了(泪).
Ubuntu下安装snap包_第1张图片

常用命令

  • snap changes 查看正在进行的change
  • sudo snap abort ID 杀死某个进程

效果

我一般在Ubuntu下写代码,所以想在Ubuntu下写笔记,同时用公式来解释代码非常直观.这是我在Ubuntu下安装Mathpix Snipping Tool的初衷.下面的公式就是用 ctr+alt+M组合键得到的公式.
R i = ( cos ⁡ ( θ i ) − sin ⁡ ( θ i ) sin ⁡ ( θ i ) cos ⁡ ( θ i ) ) \mathbf{R}_{i}=\left( \begin{array}{cc}{\cos \left(\theta_{i}\right)} & {-\sin \left(\theta_{i}\right)} \\ {\sin \left(\theta_{i}\right)} & {\cos \left(\theta_{i}\right)}\end{array}\right) Ri=(cos(θi)sin(θi)sin(θi)cos(θi))

A i j = ∂ e i j ( x ) ∂ x i = ( − R i j ⊤ R i ⊤ R i j ⊤ ∂ R i ⊤ ∂ θ i ( t j − t i ) 0 ⊤ − 1 ) \mathbf{A}_{i j}=\frac{\partial \mathbf{e}_{i j}(\mathbf{x})}{\partial \mathbf{x}_{i}}=\left( \begin{array}{cc}{-\mathbf{R}_{i j}^{\top} \mathbf{R}_{i}^{\top}} & {\mathbf{R}_{i j}^{\top} \frac{\partial \mathbf{R}_{i}^{\top}}{\partial \theta_{i}}\left(\mathbf{t}_{j}-\mathbf{t}_{i}\right)} \\ {\mathbf{0}^{\top}} & {-1}\end{array}\right) Aij=xieij(x)=(RijRi0RijθiRi(tjti)1)
对应代码

Eigen::Matrix2d Rij_inv = (Zij.topLeftCorner(2,2)).transpose();
Eigen::Matrix2d Ri_inv = (Xi.topLeftCorner(2,2)).transpose();

Eigen::Matrix2d JR_theta;
JR_theta << -Xi(1,0), Xi(0,0),
-Xi(0,0), -Xi(1,0);

Ai.setZero();
Ai.topLeftCorner(2,2) = -Rij_inv * Ri_inv;
Ai.topRightCorner(2,1) = Rij_inv * JR_theta * (Xj.topRightCorner(2,1) - Xi.topRightCorner(2,1));
Ai(2,2) = -1;

Bi.setZero();
Bi.topLeftCorner(2,2) = Rij_inv * Ri_inv;
Bi(2,2) = 1; 

参考

  • snap教程https://itsfoss.com/use-snap-packages-ubuntu-16-04/

你可能感兴趣的:(安装失败)