--scene_path
などパスを指定する引数に、001
など数値とみなされるディレクトリ名を渡したときにTypeError
が発生する問題を修正しました。
#158
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
不具合の内容
--scene_path
にはディレクトリ名を渡すこともできます。999
というディレクトリ名があったので、--scene_path 999
を指定したら、TypeError
が発生しました。原因は、
Path()
にintである値を渡したためです。Fire
は型ヒントを考慮せずに自動的に適切な型へ変換するため、今回のエラーが発生しました。#154 と同じ状況です。
修正内容
Path()
に渡す以下の引数について、Path()
に渡す前にstr()
で文字列に変換するようにしました。--scene_path
--output_dir
--kitti_dir
補足
Fireの自動的な型変換による問題はまだ残っているかもしれません。
問題が発生したときに修正しようと思います。