llsourcell / ai_composer Goto Github PK
View Code? Open in Web Editor NEWAI Composer for Machine Learning for Hackers #2
AI Composer for Machine Learning for Hackers #2
I am working on stephenbhope/Revised-CommAI-env and as part of the process unified end user & developer tool box highlighting outstanding examples of opensource apps. Are there any wish list items from contributors here for either finding the right tool or to automate a tedious bit? I want to make the tool box a stop when developers are looking for something different to their current tools, or empty spots in their set.
I'd be happy to assist with setting up the webhooks to link this repo to any of github's free testing, linting apps if it's wanted.
After doing about 150 epochs:
ubuntu@ubuntu-VirtualBox:~/AI_Composer$ rnn_sample.py --config_file new_config_file.config
rnn_sample.py: command not found
ubuntu@ubuntu-VirtualBox:~/AI_Composer$
Not sure what exactly the issue is here.
Hello,
I've been having so much trouble running source's project and making them work.
As for the AI_Composer I installed all dependencies and tried everything step by step and once over again.
I (for now) end up with the same error.
Traceback (most recent call last):
File "main.py", line 4, in <module>
import rnn
File "/home/quinten/Documents/AI_Composer/rnn.py", line 11, in <module>
import tensorflow as tf
ImportError: No module named tensorflow
I installed the correct Tensorflow. Can I please get help to get this to work. AI_Writer is a death end and I hope it's not for AI_Composer.
Again showing install of TF 0.8 and the response when running main.py
sudo pip install --upgrade https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-0.8.0-cp27-none-linux_x86_64.whl
The directory '/home/quinten/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/quinten/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting tensorflow==0.8.0 from https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-0.8.0-cp27-none-linux_x86_64.whl
Downloading https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-0.8.0-cp27-none-linux_x86_64.whl (22.2MB)
100% |████████████████████████████████| 22.2MB 90kB/s
Requirement already up-to-date: protobuf==3.0.0b2 in /usr/local/lib/python2.7/dist-packages (from tensorflow==0.8.0)
Requirement already up-to-date: wheel in /usr/local/lib/python2.7/dist-packages (from tensorflow==0.8.0)
Requirement already up-to-date: numpy>=1.8.2 in /usr/local/lib/python2.7/dist-packages (from tensorflow==0.8.0)
Requirement already up-to-date: six>=1.10.0 in /usr/local/lib/python2.7/dist-packages (from tensorflow==0.8.0)
Requirement already up-to-date: setuptools in /usr/local/lib/python2.7/dist-packages (from protobuf==3.0.0b2->tensorflow==0.8.0)
Installing collected packages: tensorflow
Found existing installation: tensorflow 0.8.0
Uninstalling tensorflow-0.8.0:
Successfully uninstalled tensorflow-0.8.0
Successfully installed tensorflow-0.8.0
quinten@quinten:~/Documents/AI_Composer$ python main.py
Traceback (most recent call last):
File "main.py", line 4, in <module>
import rnn
File "/home/quinten/Documents/AI_Composer/rnn.py", line 11, in <module>
import tensorflow as tf
ImportError: No module named tensorflow
Also when I do
python -c 'import tensorflow as tf; print(tf.__version__)'
Traceback (most recent call last):
File "<string>", line 1, in <module>
ImportError: No module named tensorflow
I tried everything is available on StackOverflow and also tried:
pip install git+https://github.com/vishnubob/python-mid i@feature/python3
but still getting the same error.
Thanks in advance.
james@:~/ai/AI_Composer$ python main.py
Traceback (most recent call last):
File "main.py", line 4, in
import rnn
File "/home/james/ai/AI_Composer/rnn.py", line 16, in
from model import Model, NottinghamModel
File "/home/james/ai/AI_Composer/model.py", line 5, in
from tensorflow.models.rnn import rnn_cell
File "/usr/local/lib/python2.7/dist-packages/tensorflow/models/rnn/rnn_cell.py", line 21, in
raise ImportError("This module is deprecated. Use tf.nn.rnn_cell instead.")
ImportError: This module is deprecated. Use tf.nn.rnn_cell instead.
(Using TensorFlow binary: https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-0.9.0-cp27-none-linux_x86_64.whl)
I looked in /usr/local/lib/python2.7/dist-packages/tensorflow/models/rnn/rnn_cell.py and sure enough it just spits out that deprecation message.
The relevant line in /home/james/ai/AI_Composer/model.py:
from tensorflow.models.rnn import rnn_cell
I'm too noob to all of this to figure out how to put tf.nn.rnn_cell in there instead. I tried this:
james@MUSSLI:~/ai/AI_Composer$ python main.py
Traceback (most recent call last):
File "main.py", line 4, in <module>
import rnn
File "/home/james/ai/AI_Composer/rnn.py", line 16, in <module>
from model import Model, NottinghamModel
File "/home/james/ai/AI_Composer/model.py", line 5
from tensorflow.models.rnn import tf.nn.rnn_cell
^
SyntaxError: invalid syntax
I tried to figure out where "tf" and "nn" are if they go in the import string somehow...
james@MUSSLI:/usr/local/lib/python2.7/dist-packages/tensorflow$ find . -name tf
james@MUSSLI:/usr/local/lib/python2.7/dist-packages/tensorflow$ find . -name nn
james@MUSSLI:/usr/local/lib/python2.7/dist-packages/tensorflow$ find . -name rnn_cell.py
./models/rnn/rnn_cell.py
./python/ops/rnn_cell.py
./contrib/rnn/python/ops/rnn_cell.py
tf and nn are not there?
Can you please specify the version of TensorFlow or solve the 0.9 issue? (Or both?)
it's possible to use this base image as a container for your program
https://github.com/tensorflow/tensorflow/tree/master/tensorflow/tools/docker
eg.
https://github.com/tensorflow/tensorflow/blob/master/tensorflow/tools/docker/Dockerfile.devel
or you can cherry pick my scripts here ->
https://github.com/johndpope/DockerParseyMcParsefaceAPI/blob/master/docker/dsparseyapi/Dockerfile
once you get a gist that you can run - update dockerfile to fetch gist and run it.
this will resolve all the other issues and speed up getting environment up and running.
eg. https://github.com/johndpope/DockerParseyMcParsefaceAPI
should be able to run
make start
and entire parsey mcparseface should download and build.
I get this message when i modify the tensorflow 0.10.0 version url to 0.8.0 version. Is this link unavaible now?
HTTP error 404 while getting https://storage.googleapis.com/tensorflow/mac/cpu/tensorflow-0.8.0-py2-none-any.whl.
Thanks in advanced.
From what i see it gets the midis from a url ..can i input my own? i tried to change the dtataset.zip but when i put in my own midis it gets error ...is it possible or is the code only able to run with the midis that are included?
I tried to use the accuracy
function from util.py. This code is from rnn.py and it computes the accuracy on the train_data :
loss, batch_prob_train = util.run_epoch(session, data["train"]["data"], training=True, testing=True)
train_losses.append((i, loss))
train_acc = util.accuracy(batch_prob_train, data["train"]["data"])
train_acc.append((i, train_acc))
I'm getting the error :
Traceback (most recent call last):
File "rnn.py", line 113, in <module>
train_acc = util.accuracy(batch_prob_train, data["train"]["data"])
File "/home/calin/BitBucket/Music-Language-Modelling/music-language-modelling/core_venv/util.py", line 265, in accuracy
num_time_steps = len(batch_data)
TypeError: object of type 'function' has no len()
Got this error while running python rnn_sample.py --config_file new_config_file.config
if not newclass.is_abstract():
AttributeError: type object 'NewBase' has no attribute 'is_abstract'
/home/eumi/AI_Composer-master/main.py: line 7: url: command not found
/home/eumi/AI_Composer-master/main.py: line 8: syntax error near unexpected token url,' /home/eumi/AI_Composer-master/main.py: line 8:
urllib.urlretrieve(url, "dataset.zip")'
i get this error on my linux =/ is there a way that i just download this zipfile and edit main.py so it reads it from drive ...so that i also (once its working) change the input it gets?
Can you share an configuration file sample?
Hi,
After I ran the training for hour and found a message like
Epoch: 29, Train Loss: 0.547316406171, Time Per Epoch: 146.813248034
Valid Loss: 0.572111875409
Best loss so far encountered, saving model.
According to README, I think I can stop running training and started to generate new MIDI song but after I ran the command for generating. it turned out that they can't find the given config file.
Did I miss any steps? please suggest.
Thanks!
Number of chords: 0
Max Sequence length: 0
Avg Sequence length: 0
Num Sequences: 0
In def parse_nottingham_directory(input_dir, time_step, verbose=False):
these lines of code:
# filter out the non 2-track MIDI's
sequences = filter(lambda x: x[1] != None, sequences)
remove all sequences.
Is the data in the dataset.zip good?
i was trying this out and i got this im not good with code what am i doing wrong?
Traceback (most recent call last):
File "main.py", line 4, in
import rnn
File "/home/parrot/Documents/AI_Composer-master/rnn.py", line 16, in
from model import Model, NottinghamModel
File "/home/parrot/Documents/AI_Composer-master/model.py", line 5, in
from tensorflow.models.rnn import rnn_cell
ImportError: No module named models.rnn
trained for 25 epoch....
after run
python rnn_sample.py --config_file models/0425_1816/nl_2_hs_200_mc_0p5_dp_0p5_idp_0p8_tb_128.config
it generated best.midi
but i couldn't play it whether on ubuntu or windows
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.