Skip to content

Instantly share code, notes, and snippets.

from transformers import GPT2Tokenizer, GPT2LMHeadModel
import torch
# Load pre-trained GPT-2 model and tokenizer
tokenizer = GPT2Tokenizer.from_pretrained('gpt2')
model = GPT2LMHeadModel.from_pretrained('gpt2')
# Input prompt
prompt = "Once upon a time in a faraway land"
input_ids = tokenizer.encode(prompt, return_tensors='pt')

Diff editor colors

Key Desctiption
diffEditor.insertedTextBackground Background color for text that got inserted. The color must not be opaque so as not to hide underlying decorations.
diffEditor.insertedTextBorder Outline color for the text that got inserted.
diffEditor.removedTextBackground Background color for text that got removed. The color must not be opaque so as not to hide underlying decorations.
diffEditor.removedTextBorder Outline color for text that got removed.
diffEditor.border
@DolphinOfficial
DolphinOfficial / PostShutdownFullLog.txt
Created February 7, 2025 22:52
Text file created by Roblox
-- AH POST-SERVER LOGS --
-- ServerID: 77325816-52ea-45d8-b56f-7d5fbe188bbe
-- Server started: February 07, 2025 10:51 PM UTC | Server uptime: 44 seconds
------------------ LOADB LOGS ------------------
{
}
@choco-bot
choco-bot / FilesSnapshot.xml
Created February 7, 2025 22:51
boost-msvc-14.3 v1.87.0 - Passed - Package Tests Results
<?xml version="1.0" encoding="utf-8"?>
<fileSnapshot xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<files>
<file path="C:\ProgramData\chocolatey\lib\boost-msvc-14.3\boost-msvc-14.3.nupkg" checksum="D2E4C08A949702B7978AEA32E7A71578" />
<file path="C:\ProgramData\chocolatey\lib\boost-msvc-14.3\boost-msvc-14.3.nuspec" checksum="BCA60C3666EBA5E98A23B945D48D3BEC" />
<file path="C:\ProgramData\chocolatey\lib\boost-msvc-14.3\tools\chocolateyInstall.ps1" checksum="1C1F571DD8B5C15BA4148BB971C3BB99" />
<file path="C:\ProgramData\chocolatey\lib\boost-msvc-14.3\tools\chocolateyuninstall.ps1" checksum="AF4990B6B9190FBEE0197D2306698C61" />
</files>
</fileSnapshot>
@yuzisun
yuzisun / gist:ad5b06ae8b3b2eaf245664fd6cfabf8a
Created February 7, 2025 22:51
text2bql-ned app revisions
{
"items": [
{
"metadata": {
"creationTimestamp": "2024-08-29 00:00:45 +0000 UTC",
"labels": {
"mlp.bloomberg.com/application-revision-alias": "text2bql-ned-argo-dev-2024-08-28",
"yas.bloomberg.com/application-name": "text2bql-ned",
"yas.bloomberg.com/embedded-resource-name": "text2bql-ned-argo-dev"
},
@DolphinOfficial
DolphinOfficial / PostShutdownFullLog.txt
Created February 7, 2025 22:51
Text file created by Roblox
-- AH POST-SERVER LOGS --
-- ServerID: bfcdcb33-4397-4414-b116-230e671ccd3b
-- Server started: February 07, 2025 10:51 PM UTC | Server uptime: 3 seconds
------------------ LOADB LOGS ------------------
{
}
@forkyau
forkyau / hourly_rainfall_data-2025-02-08|06-30.csv
Created February 7, 2025 22:51
GIST created by python code
id station stationid value unit obstime date
0 流浮山 RF001 0 mm 2025-02-08T06:30:00+08:00 2025-02-08
1 湿地公园 RF002 0 mm 2025-02-08T06:30:00+08:00 2025-02-08
2 水边围 N12 0 mm 2025-02-08T06:30:00+08:00 2025-02-08
3 石岗 RF003 0 mm 2025-02-08T06:30:00+08:00 2025-02-08
4 大美督 RF004 0 mm 2025-02-08T06:30:00+08:00 2025-02-08
5 大埔墟 RF005 0 mm 2025-02-08T06:30:00+08:00 2025-02-08
6 北潭涌 RF006 0 mm 2025-02-08T06:30:00+08:00 2025-02-08
7 滘西洲 RF007 0 mm 2025-02-08T06:30:00+08:00 2025-02-08
8 西贡 N15 0 mm 2025-02-08T06:30:00+08:00 2025-02-08
@DolphinOfficial
DolphinOfficial / PostShutdownFullLog.txt
Created February 7, 2025 22:51
Text file created by Roblox
-- AH POST-SERVER LOGS --
-- ServerID: e14210bc-6419-49fc-af79-8a3328846872
-- Server started: February 07, 2025 08:33 PM UTC | Server uptime: 7907 seconds
------------------ LOADB LOGS ------------------
{
}
@HugsLibRecordKeeper
HugsLibRecordKeeper / output_log.txt
Created February 7, 2025 22:50
Rimworld output log published using HugsLib
Log uploaded on Saturday, February 8, 2025, 2:50:32 AM
Loaded mods:
Harmony(brrainz.harmony)[mv:2.3.1.0]: 0Harmony(2.3.3), HarmonyMod(2.3.1)
Core(Ludeon.RimWorld): (no assemblies)
Royalty(Ludeon.RimWorld.Royalty): (no assemblies)
Ideology(Ludeon.RimWorld.Ideology): (no assemblies)
Biotech(Ludeon.RimWorld.Biotech): (no assemblies)
HugsLib(UnlimitedHugs.HugsLib)[ov:11.0.4]: 0Harmony(av:2.3.3,fv:1.2.0.1), HugsLib(av:1.0.0,fv:11.0.4)
Vanilla Expanded Framework(OskarPotocki.VanillaFactionsExpanded.Core): 0ModSettingsFramework(1.0.0), 0MultiplayerAPI(av:0.3.0,fv:0.3.0), 0PrepatcherAPI(1.1.1), ExplosiveTrailsEffect(1.0.7140.31563), GraphicCustomization(1.0.0), HeavyWeapons(1.0.0), KCSG(av:1.1.2,fv:25.2.3), MVCF(2.0.0.1), NoCamShakeExplosions(1.0.0), OPToxic(1.0.0), Outposts(av:3.0.0,fv:1.0.0), PipeSystem(av:1.0.1,fv:22.7.29), RecipeInheritance(1.0.1), RRO(1.0.0), SmokingGun(1.0.0), VanillaStorytellersExpanded(1.0.0), VanillaWeaponsExpandedLaser(0.0.0), VFECore(av:1.1.7,fv:1.1.9), VWEMakeshift(1.0.0)
Vanilla Races Ex
# frozen_string_literal: true
module Decidim
module System
module SystemMenuOverride
extend ActiveSupport::Concern
included do
def self.register_system_menu!