Juliaでもglobは使える![Julia]

Pythonでお世話になっているglob.*を使ってパターンマッチングしてくれるから,フォルダ内のファイルを読み込む際にとっても便利だ.
そんなglobだが,実はJuliaでも同様のライブラリが存在する!
これ ...
フォーマット済み文字列リテラルの便利な使い方[Python]

Python3.6から追加されたフォーマット済み文字列リテラルを便利に使ってるなあと思った事例をいくつか紹介.
今後も見つけるたびに追加していこうと思う.
Bashのように{hoge}で変数を使うKaggleで ...
defに付いてる->ってどういう意味?[Python]

Kaggleのコードを読んでいると以下のような記法を見つけた.
def greeting(name: str) -> str:return 'Hello ' + nameん? -> ってなんぞ?
調 ...
CoNLL-2003の横についてる単語ってどういう意味?

NER(固有表現抽出)の評価の際によくでてくるCoNLL-2003.
データセットを眺めていると, 単語の横にPRP や B-NP, O などの記号が付いている.
これってどういう意味なの? と思ったので調べて ...
汎用言語モデルBERTをつかってNERを動かしてみる

本記事は,2018秋にバズった汎用言語モデルBERTをとりあえずつかってみたときのレポートである.
このBERTというモデルをpre-trainingに用いると,様々なNLPタスクで高精度がでるようだ.詳細に関しては以下の ...
PDFを画像に変換する

ImageMagickのconvertコマンドを使う。
convert -density 150 7181-attention-is-all-you-need.pdf -quality 90 output.png上を実行す ...
コマンドラインでPDFから図を抽出

Popplerの付属コマンド、pdfimagesを使う。
# Popplerが入って無ければ入れる# install popperpdfimages -p -png hoge.pdf paper_figを実行するとpap ...
Proxy環境下でpip[Python]

pip install hoge --proxy
データをopenするときの第2引数 r+, w+, a+の違いって何?[Python]

導入
“r+” と “w+” と “a+” における挙動の違い“r+” の場合
“w+” の場合
...
“r+” と “w+” と “a+” における挙動の違い“r+” の場合
“w+” の場合
...
Pythonでテキストファイルを1行ずつ読み込む[Python]

with open("text.txt") as f:for line in f:print(line)
withを使いたくなければ,
f = open("text.txt")for line in f:print(line)f. ...