Skip to main content

SIGNATE CLI

Project description

SIGNATE CLI

SIGNATE の公式APIコマンドラインインターフェイス(以下:SIGNATE CLI)です。
SIGNATEはData Science Competitionのご提供を始めとした、データサイエンティストの皆様のための統合プラットフォームです。

※SIGNATE CLIの動作にはPython3.6 以降の環境が必要です。
※当CLIはβ版であり、予告なく変更させていただく可能性がございます。予めご了承ください。
※SIGNATE CLIはMac OSおよびLinuxをサポートしております。

インストールと事前準備

以下のコマンドでインストールをお願いいたします。

$ pip install signate

インストール後、以下の手順を実施ください。

  1. SIGNATE でアカウント登録
  2. アカウント登録後、プロフィール 画面の "API Token" をクリック
  3. "新規作成" をクリックしてAPI Token(signate.json)を取得
  4. 取得したAPI Tokenを ~/.signate直下に配置

以下のコマンドでヘルプが表示されましたら利用準備完了です。

$ signate --help

signate: command not found と表示される場合、環境変数$PATH のディレクトリ内にsignateが存在していることをご確認ください。pip uninstall signateコマンドで

  • signateコマンドがインストールされているディレクトリの確認
  • signateコマンドのアンインストール

が可能です。

利用方法

SIGNATE CLIでは以下の機能が利用できます。

$ signate --help
Usage: signate [OPTIONS] COMMAND [ARGS]...

Options:
  --help  Show this message and exit.

Commands:
  download  Download the file of competition
  files     List file of competition
  list      List competition
  submit    Submit a result file to the competition

① 投稿可能なコンペティション一覧の取得

$ signate list 

投稿可能なコンペティション一覧を表示します。

$ signate list 

competitionId  title             closing              prize        participants
-------------  ----------------  -------------------  ---------  --------------
   1           a-ai-competition  -                    $200,00               100
   2           b-ai-competition  2019-12-31           Knowledge              50
……

② コンペティションが提供するファイル一覧の取得

$ signate files --competition-id=<competition-id> 

コンペティションが提供するファイルの一覧を表示します。

$ signate files --competition-id=1

  fileId  name               title              size  updated_at
--------  -----------------  --------------  -------  -------------------
       1  train.csv          学習用データ      2345067  2016-05-31 11:19:48
       2  test.csv           検証用データ      1523536
……

③ コンペティションが提供するファイルのダウンロード

こちらの機能をご利用の場合、コンペティションへの参加に同意いただく必要がございます(同意前の場合)。
詳しくは補足 コンペティションへの同意をご確認ください。

$ signate download --competition-id=<competition-id> 

コンペティションが提供するファイルをダウンロードします。 デフォルトの場合カレントディレクトリにファイルがダウンロードされます。
competition-idのみを指定した場合、該当コンペティションが提供するすべてのファイルがダウンロード対象となります。

$ signate download --competition-id=1 
submit_sample.csv
100% [.................................................................] 205890 / 205890
test.csv
100% [.................................................................] 1523536 / 1523536
train.csv
100% [.................................................................] 2345067 / 2345067

Download completed.

以下のようにご指定いただくことで、ダウンロードするファイルの指定とダウンロード先のパス指定もそれぞれ可能です。

$ signate download --competition-id=1 --file-id=1 --path=/Users/[user_name]/Desktop/
train.csv
100% [.................................................................] 2345067 / 2345067

Download completed.

④ データセットの提出

こちらの機能をご利用の場合、コンペティションへの参加に同意いただく必要がございます(同意前の場合)。
詳しくは補足 コンペティションへの同意をご確認ください。

signate submit --competition-id=<competition-id> <結果ファイルのパス>

コンペティションにデータセットを提出します。

$ signate submit --competition-id=1 /Users/[user_name]/Desktop/result.csv
You have successfully submitted your predictions. We will send you the submission result to your email address.

コメントを残すことも可能です。

$ signate submit --competition-id=1 /Users/[user_name]/Desktop/result.csv --note 頑張りました
You have successfully submitted your predictions. We will send you the submission result to your email address.

補足

コンペティションへの同意

以下のようなメッセージが出力された際は

You have not accepted the competition terms of use!

Do you accept the competition terms of use?
Please read the terms of use before accepting: https://signate.jp/competitions/*#terms
 [y/N]:

リンク先をご一読いただき、y のご入力をお願いいたします。以降、同一コンペティションで当メッセージは表示されません。

プロフィール入力の不足

You have not filled in user infomation to join the competition. Go to https://signate.jp/profile.

のメッセージが表示された場合はSIGNATEにアクセスいただき、プロフィールのご入力をお願いいたします。

その他

日本語タイトルのファイル投稿はサポート対象外です。ご了承ください。

ライセンス

SIGNATE CLIはApache 2.0 license. を適用しております。

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

signate-0.9.0.tar.gz (20.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

signate-0.9.0-py3-none-any.whl (31.7 kB view details)

Uploaded Python 3

File details

Details for the file signate-0.9.0.tar.gz.

File metadata

  • Download URL: signate-0.9.0.tar.gz
  • Upload date:
  • Size: 20.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.3

File hashes

Hashes for signate-0.9.0.tar.gz
Algorithm Hash digest
SHA256 84469e4b37d5c1a5caa0fa0aff7489ef1d146fdf63b4507ce7eb28ca2d3e0c92
MD5 a55e52c8fbbc9fcb82423d919d77c6ad
BLAKE2b-256 c60bba7dc9da7512a3d2a8291e25e35fdc4b46774628f1ea7396d5f1270ca54b

See more details on using hashes here.

File details

Details for the file signate-0.9.0-py3-none-any.whl.

File metadata

  • Download URL: signate-0.9.0-py3-none-any.whl
  • Upload date:
  • Size: 31.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.3

File hashes

Hashes for signate-0.9.0-py3-none-any.whl
Algorithm Hash digest
SHA256 547078b21b66d7e3b22303d2d514545cfe4ca15083faa2d2ad8765da7142653c
MD5 a4ad047872520e98e113b8e3f49c4774
BLAKE2b-256 48ce0202c9297bfb72dc4c4fb6b2f260fd9f8d241d9de164f489c6b2bad70c06

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page