sbt scalafmtCheckAll
sbt scalafmt
sbt test:scalafmt
<div class="title">カードのタイトル部分</div>
.button {
corner-shape: squircle; /* スムーズな角丸 */
corner-shape: bevel;
corner-shape: notch;
corner-shape: scoop;
}
{% assign base_classname = 'image-gallery' %}
<div class="image-gallery-wrapper">
{% if Module.FieldValues.Content != nil and Module.FieldValues.Content != '' %}
<header class="element-header">{{Module.FieldValues.Content}}</header>
{% endif %}
<section class="{{base_classname}} col-span-{{Module.FieldValues.ColumnCount | Default: '4'}}" data-gallery="gallery-{{Module.MatrixModuleId}}">
<div class="grid-sizer"></div>
{% for item in List.Items %}
{% assign rand
.product-card:has(a:hover, button:hover, [role="button"]:hover, input[type="submit"]:hover) {
}
/**
* @param {string} s1
* @param {string} s2
* @param {string} baseStr
* @return {string}
*/
class UnionFind {
constructor() {
this.parent = Array.from({ length: 26 }, (_, i) => i); // 'a' to 'z' mapped to 0-25
}
// Find root of the character index
find(x) {
if (this.parent[x] !== x) {
this.parent[x] = this.find(this.parent[x]); // Path compression
}
return this.parent[x];
}
// Union two sets
union(x, y) {
l
sudo nano /etc/default/grub
GRUB_CMDLINE_LINUX_DEFAULT="consoleblank=180"
sudo update-grub
sudo reboot
import logging
logger = logging.getLogger(__name__)
logging.basicConfig(
level=logging.INFO,
format="%(asctime)s [%(levelname)s] %(name)s: %(message)s",
)
SELECT OWA_UTIL.GET_CGI_ENV('REQUEST_SCHEME') || '://' ||
OWA_UTIL.GET_CGI_ENV('SERVER_NAME') ||
OWA_UTIL.GET_CGI_ENV('SCRIPT_NAME') || '/'
AS L_AI_INSTANCIA_URL
FROM DUAL;
Host *
Port 22
Host vm_*
IdentityFile ~/.ssh/ed25519_VM
BatchMode yes
Host vm_node1
HostName 192.168.56.1 # or vm.example.com
.modal {
/* Hidden state */
display: none;
opacity: 1;
}
.modal.open {
display: block;
/* Regular transition works now */
transition: opacity 300ms;
opacity: 1;
}
/* Define starting styles when modal becomes displayed */
@starting-style {
.modal.open {
opacity: 0;
}
}
# tracemalloc
```
import tracemalloc
pre_snapshot = None
tracemalloc.start()
xxx
snapshot = tracemalloc.take_snapshot()
global pre_snapshot
if pre_snapshot:
top_stats = snapshot.compare_to(pre_snapshot, 'lineno')
for stat in top_stats[:10]:
print(stat)
else:
pre_snapshot = snapshot
```
import { jwtVerify } from 'jose'
import { JWT_SECRET } from '@/constants/config'
interface IShipmentTokenPayload {
id: string
fields: string
subId?: number
nonce?: string
}
export async function decodeShipmentToken(token: string): Promise<{
id: string
subId?: number
fieldsArray: Array<{ name: string; order: number }>
} | null> {
try {
if (!token || token.length < 10) {
console.error('Invalid token format or length')
return null
}
const { payload } = awa
/**
* Finds the lexicographically largest substring based on the number of friends.
* If `numFriends` is 1, the whole word is returned.
* Otherwise, the function finds the best substring by iterating through possible slices.
*
* @param {string} word - The input word.
* @param {number} numFriends - The number of friends involved in the selection process.
* @return {string} - The lexicographically largest substring.
*/
var answerString = function (word, numFriends) {
// If only one fri
# tokenizer
```
AutoTokenizer.from_pretrained("...", use_fast=False)
```
* use_fast:默认为 ture,使用 rust 实现,多线程处理,会分配和 cpu 核数相同的线程数。
Ref.:
1. https://huggingface.co/docs/transformers/en/model_doc/auto#transformers.AutoTokenizer.from_pretrained.use_fast
2. https://github.com/huggingface/tokenizers/tree/main/tokenizers#features
<!-- Tag <html> de abertura ao codigo html -->
<html>
<!-- Tag <head> para incluir estilos CSS, título, codificação de caracteres, etc. -->
<head>
<!-- Tag <style> é usada para definir os estilos CSS -->
<style>
/* Centraliza o texto da DIV e coloca a altura em 300px */
.dashboard-total {
text-align: center;
height: 300px;
}
/* Edita o texto da tag H1 da DIV */
.dashbo