01_ddim_inversion_CN

DDIM reverse Settings # !pip install -q transformers diffusers accelerate import torch import requests import torch.nn as nn import torch.nn.functional as F from PIL import Image from io import BytesIO from tqdm.auto import tqdm from matplotlib import pyplot as plt from torchvision import transforms as tfms from diffusers import StableDiffusionPipeline, DDIMScheduler # Useful function for […]

Euler angles (roll angle, pitch angle, yaw angle), rotation matrix, quaternion conversion and solution to universal joint deadlock

1. Overview The description method of the pose (position and direction) of an object is generally represented by two coordinate systems. One is the world coordinate system or the ground coordinate system. Here I call it the ground coordinate system, which belongs to the reference coordinate system; the other is its own Coordinate system, it […]

Modern C++ conversion constructors and type conversion functions

In C/C++, different data types can be converted to each other. The type that does not require the user to specify how to convert is called automatic type conversion (implicit type conversion), and the type that requires the user to explicitly specify how to convert is called forced type conversion. Whether it is automatic type […]

Collect the use of different rich text editors (vue3 version)

Article directory 1. ueditor (Baidu Rich Text Editor) Install Use and re-package components 2. KindEditor download file Create new components and use them 1. ueditor (Baidu Rich Text Editor) Reference ueditor and vue-ueditor-wrap The encapsulated vue component is used directly here vue-ueditor-wrap vue3 version Installation npm i [email protected] -S or yarn add [email protected] Use and […]

C# lunar calendar and solar calendar related tool conversion class

I need to take out things from a long time ago and sort them out after using them again. relatively forgetful Gregorian calendar to lunar calendar //Under this namespace using System.Globalization; //There is a class dedicated to calculating the Chinese lunar calendar ChineseLunisolarCalendar cnsc = new ChineseLunisolarCalendar(); ChineseLunisolarCalendar cnsc = new ChineseLunisolarCalendar(); DateTime jrLDate = […]

Solve the problem that the Onlyoffice file version changes and the problem that multiple people cannot edit collaboratively after using dynamic keys

1.Cause analysis Onlyoffice’s file saving mechanism relies on the callback interface to save files. Once the file is saved successfully. When the editor is opened again with the last key and the latest document URL address as parameters, the editor service goes to redis to find the cache based on the key and verifies whether […]

java version conversion gadget

In my spare time, I wrote a conversion gadget with the following functions: timestamp conversion Base64 encoding/decoding URL encoding/decoding JSON formatting Time stamp conversion package org.binbin.container.panel; import javax.swing.*; import java.awt.*; import java.text.DateFormat; import java.text.SimpleDateFormat; import java.util.Date; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; /** * *Copyright ? All Rights Reserved by VenusChen * * @author Hu Haibin/[email protected] * […]

Install stand-alone version of hadoop-3.3.6 on linux

1. Download hadoop https://mirrors.tuna.tsinghua.edu.cn/apache/hadoop/core/hadoop-3.3.6/ 2. Configure environment variables 1. Configure java environment variables 2. Configure hadoop environment variables export HADOOP_HOME=/usr/local/bigdata/hadoop-3.3.6 export HBASE_HOME=/usr/local/bigdata/hbase-2.5.6 export JAVA_HOME=/usr/local/jdk-11 export CLASSPATH=.:$JAVA_HOME/lib export PATH=.:$JAVA_HOME/bin:$HBASE_HOME/bin:$HADOOP_HOME/bin:$PATH 3. Configure host 192.168.42.142 node4 3. Modify the configuration file corresponding to hadoop 3.1. Create a directory under the hadoop directory mkdir logs mkdir data mkdir -p […]

[C++] Type conversion [4 types of type conversion]

Table of Contents 1. Type conversion in C language 2. Four type conversions in C++ 2.1 static_cast 3.2 reinterpret_cast 3.3 const_cast 3.4 dynamic_cast 3. express 4. RTTI (Understand) 1. Type conversion in C language exist C language, if The left and right sides of the assignment operator have different types, or the formal parameter types […]

The four major streams in Java: [buffer stream] [conversion stream] [object stream] [print stream]

Article directory buffered stream 1 Overview 2. Efficiency test byte buffer stream character buffer stream Conversion flow Character encodings and character sets Character Encoding character set InputStreamReader class Specify encoding to read OutputStreamWriter class Specify encoding to write object stream ObjectOutputStream class Serialization operation ObjectInputStream class print stream This article mainly introduces the basic concepts […]