batch-file

How to create a conda environment shortcut on Windows

How to create a conda environment shortcut on Windows Question: With Anaconda installed I got a anaconda base shortcut on Windows startmanu. To open the virtualenv I created (e.g., myenv), I have to click the anaconda base and type in activate myenv in the opened cmd window. How can I create a shortcut to get …

Total answers: 6

Activate virtualenv and run .py script from .bat

Activate virtualenv and run .py script from .bat Question: I’d like to use Windows Task Scheduler to run a python script within a virtual environment. I’d like the Scheduler to run a .bat file that will activate the virtualenv run the script These steps work together from the command line, and they work individually in …

Total answers: 6

Split audio files using silence detection

Split audio files using silence detection Question: I’ve more than 200 MP3 files and I need to split each one of them by using silence detection. I tried Audacity and WavePad but they do not have batch processes and it’s very slow to make them one by one. The scenario is as follows: split track …

Total answers: 4

GIMP on Windows – executing a python-fu script from the command line

GIMP on Windows – executing a python-fu script from the command line Question: In a Windows environment, I would like to make a call to GIMP for executing a python-fu script (through a BAT file) but the command line call I am using does not produce the expected results. For example, consider the following python-fu …

Total answers: 3

Running Python file by double-click

Running Python file by double-click Question: I have really annoying problem, I cannot run a Python file just by double-clicking. I have tried to set it to open the file with idle.bat but that only starts IDLE editor on double-click, it does not run the Python file. Asked By: Bob || Source Answers: What version …

Total answers: 7

Cannot use 'pyside-rcc' to compile .qrc file

Cannot use 'pyside-rcc' to compile .qrc file Question: I am working on python project and I have a problem with pyside-rcc. First, let I explain briefly about my project. I created my project GUI in QtDesigner and also use the image in the GUI. Then, I generate .py from .ui file using pyside-uic and it …

Total answers: 4

Batch file: Run command for every file of certain extension

Batch file: Run command for every file of certain extension Question: I run a python command python file.py inputfile.stl but I want to expand it to input several files at a time. How would I make a windows batch file that when ran, will run a command for every *.stl file in that directory. So …

Total answers: 1

Python equivalent for batch Choice command

Python equivalent for batch Choice command Question: I’m working on a small project in python, and after a bit of work on it I was wondering if there was a way of inputting data in python 3 which was somewhat similar to batch’s choice command. Pretty much only take in one key of input and …

Total answers: 1

Python to .bat conversion

Python to .bat conversion Question: I would like a user on Windows to be able to run my Python program, so I want to convert it to a .bat file. Is there a way to convert it? I’ve tried searching, but didn’t find anything. Asked By: JJ Beck || Source Answers: No, I don’t think …

Total answers: 5

To prevent a function from printing in the batch console in Python

To prevent a function from printing in the batch console in Python Question: Well, the headline seems to me sufficient. I use some function that at some points print something in the console. As I can’t modify them, I would like to know if there is a solution to not printing while using these functions. …

Total answers: 6