How to use `batteryml` command line tool in Windows?
Closed this issue · 10 comments
Download the raw data and run the two commands used in the preprocessing script:
I type in the Command Prompt and it says 'batteryml' is not recognized as an internal or external command, operable program or batch file.
Entering in Windows PowerShell executes successfully but without any action and result. Just skipped it.
What is the problem?
We did not test our tool in Windows. The command batteryml
is installed by Python using the setup.py
. Can you provide more information of how you install the package and your Python environment?
You should use windows powershell and use batteryml
instead of BatteryML
. The command line is case-sensitive. Also, make sure your python environment is in PATH
.
Can you share the output of echo %PATH%
in the command prompt? Make sure that the Scripts
folder is in your PATH, which holds the custom scripts installed using setup.py
.
Same problem here. Working on Windows 10. I have found the batteryml file in the bin folder as well as in my python environment folder. I have tried using both Paths but none worked. Any solution?
This error indicates the script batteryml
is not found. I will test on Windows 10. Please stay tuned.
After some investigation, I made this work under Windows. The cause was the setup.py
. We initially depended on the shebang line, e.g. #!/usr/bin/python
, in bin/batteryml
to work in Linux. Under Windows, pip cannot determine the correct entry point for this script. I got two solutions to this issue.
- (Quick) Use bash under windows. For example, if you installed git, there may be a
Git Bash
, which you may find in your option menu after right click. - I will create a PR later to fully address this issue. The key is to use
entry_points
insetup.py
.