注意:本文内容适用于 Tmux 2.3 及以上的版本,但是绝大部分的特性低版本也都适用,鼠标支持、VI 模式、插件管理在低版本可能会与本文不兼容。
启动新会话:
tmux [new -s 会话名 -n 窗口名]
恢复会话:
| """ | |
| Helper module for displaying ROOT canvases in ipython notebooks | |
| Usage example: | |
| # Save this file as rootnotes.py to your working directory. | |
| import rootnotes | |
| c1 = rootnotes.default_canvas() | |
| fun1 = TF1( 'fun1', 'abs(sin(x)/x)', 0, 10) | |
| c1.SetGridx() |
| import FWCore.ParameterSet.Config as cms | |
| externalLHEProducer = cms.EDProducer("ExternalLHEProducer", | |
| args = cms.vstring("/home/stqian/gridpack/herwig_dyellell012j_5f_NLO_FXFX_slc6_amd64_gcc630_CMSSW_9_3_16_tarball.tar.xz"), | |
| nEvents = cms.untracked.uint32(5000), | |
| numberOfParameters = cms.uint32(1), | |
| outputFile = cms.string('cmsgrid_final.lhe'), | |
| scriptName = cms.FileInPath('GeneratorInterface/LHEInterface/data/run_generic_tarball_cvmfs.sh') | |
| ) |
| import uproot4, uproot | |
| import awkward1 as ak | |
| import numba as nb | |
| from uproot3_methods import TLorentzVectorArray, TLorentzVector | |
| import os | |
| import feather | |
| import numpy as np | |
| import boost_histogram as bh | |
| import matplotlib.pyplot as plt |
| 0) You can get the complete tutorial about CRAB3 | |
| https://twiki.cern.ch/twiki/bin/view/CMSPublic/WorkBookCRAB3Tutorial (UPDATED TWIKI PAGE) | |
| For impatient users, a cheat-sheet is available | |
| https://twiki.cern.ch/twiki/bin/viewauth/CMS/CRAB3CheatSheet | |
| 1) login to lxplus SLC6 machine by doing | |
| ssh -Y username@lxplus.cern.ch | |
| 2) source LCG GRID UI by |
| # Default termtype. If the rcfile sets $TERM, that overrides this value. | |
| set -g default-terminal screen-256color | |
| # support logging out and back in | |
| set -g update-environment "SSH_ASKPASS SSH_AUTH_SOCK SSH_AGENT_PID SSH_CONNECTION" | |
| # pbcopy support | |
| set-option -g default-command "reattach-to-user-namespace -l bash" | |
| # vi mode |
Matplotlib is a plotting library. It relies on some backend to actually render
the plots. The default backend is the agg backend. This backend only renders
PNGs. On Jupyter notebooks the matplotlib backends are special as they are
rendered to the browser. Generally you will not need to explicitly set the
backend on a Jupyter notebook. This does introduce a discrepancy between code
that runs in Jupyter and code that runs as a script natively in the Python
interpreter. So you need to understand that the 2 environments are not the same
| <!DOCTYPE html> | |
| <meta charset="utf-8"> | |
| <link rel="stylesheet" href="http://cmx.io/v/0.1/cmx.css"/> | |
| <script src="http://cmx.io/v/0.1/cmx.js"></script> | |
| <body> | |
| <div style="max-width:1800px; -webkit-transform:rotate(0deg)"> | |
| <scene id="scene1" height="400" width="400"> | |
| <label t="translate(0,400)"> | |
| <tspan x="0" y="0em">SM Neutrinos are massless</tspan> |
| # ... Other .zshrc contents above | |
| function cursor() { | |
| /opt/cursor.appimage --no-sandbox "$@" >/dev/null 2>&1 & | |
| } | |
| # I used the default settings in the cursor install script here |