DrayfieldR / MidiAnalyzer

Analyze and Convert MIDI Files with ease using this versatile Python tool. Study MIDI composition, create custom annotations, and convert text to MIDI effortlessly.
MIT License
0 stars 0 forks source link

Difficulty Getting PrettyMidi to Run #1

Open Magenta-6 opened 3 weeks ago

Magenta-6 commented 3 weeks ago

I'm having difficulty figuring out how to run the program. I prefer to use the GUI, rather than the command line as I'm not python literate.

The readme files says

  1. Drag and drop MIDI files onto the midi_analyzer.py file to analyze them. Not quite sure how to do this.

Is there a .bat file I need to get this to run? Not sure whether I need to activate a virtual environment first.

Kind regards

PS - In cmd I ran > pip install pretty_midi which installed pretty_midi into my root directory. When I inspected the folder it didn't have the required .py files so . . . Then in a drive I use for music I ran cmd again >git clone https://github.com/DrayfieldR/MidiAnalyzer.git

Clip_9

DrayfieldR commented 3 weeks ago

Hi there,

To use the drag-and-drop feature, drag your MIDI file directly onto the midi_analyzer.py file in your file explorer.

Screenshot 2024-08-19 143953

The script will automatically run and analyze the file, and the processed results will appear in the analyzed folder.—no need for a .bat file or a virtual environment.

I may add a full GUI in the future to make it even easier to use.

Let me know if that works. If you have any other questions, feel free to ask!

Magenta-6 commented 3 weeks ago

Thanks for posting the screenshot.
That's pretty much what I was trying to do too, however when I try to drag the midi file over the midi_analyzer.py I don't get the option to open it. Is there a way to do this in the command line?

DrayfieldR commented 3 weeks ago

Thanks for posting the screenshot. That's pretty much what I was trying to do too, however when I try to drag the midi file over the midi_analyzer.py I don't get the option to open it. Is there a way to do this in the command line?

If the drag-and-drop isn’t working, you can run the script via the command line:

Open the command prompt. Navigate to the directory where midi_analyzer.py is located. Run the following command:

python midi_analyzer.py C:\Users\YourUsername\Documents\MyMIDIFile.mid

Replace C:\Users\YourUsername\Documents\MyMIDIFile.mid with the path to your actual MIDI file.

Let me know if this works for you!