Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create topic based on hash #10

Merged
merged 5 commits into from
Jun 22, 2018
Merged

Create topic based on hash #10

merged 5 commits into from
Jun 22, 2018

Conversation

kimamula
Copy link
Contributor

@kimamula kimamula commented Jun 21, 2018

URL の hash に基づいて制御対象のロボット、車輪を決めるようにしました 25f496d

ついでに、 tslint の導入 33f707f と CI で travis を使う 0bdac00 のもやってみました

@kimamula kimamula force-pushed the create-topic-based-on-hash branch from d7a9f73 to 0bdac00 Compare June 21, 2018 05:45
@kimamula
Copy link
Contributor Author

2018-06-21 14 48 53

UI は雑ですがこんなイメージ

@@ -179,7 +187,7 @@ const predict = async () => {
const predicted = tf.tidy(() => {
const img = capture(webcamera);
const activation = mobilenet.predict(img);
const predictions = model.predict(activation) as tf.Tensor<tf.Rank>;
Copy link
Contributor

@chooblarin chooblarin Jun 21, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

僕の環境だとこのキャストが無いとエラーになるんですが,今村さんの環境ではイケてます?

[ts]
Property 'as1D' does not exist on type 'Tensor<Rank> | Tensor<Rank>[]'.
  Property 'as1D' does not exist on type 'Tensor<Rank>[]'.
any

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

おっと。すみません自分の環境でも tsc ではエラーでした。。
tslint の設定見直します!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

palantir/tslint#2736 に上がっているバグで、 no-unused-variable を使っていると他の rule (今回は no-unnecessary-type-assertion)が壊れる場合があり、それにはまっていたようなので、 no-unused-variable を無効にし、代わりに tsconfig.jsonnoUnusedLocalsnoUnusedParameters を使うようにしました。
また、 CI のチェックで tsc が通ることも確認するようにしました。

Copy link
Contributor

@chooblarin chooblarin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@chooblarin chooblarin merged commit a997f89 into master Jun 22, 2018
@chooblarin chooblarin deleted the create-topic-based-on-hash branch June 22, 2018 01:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants