-
Notifications
You must be signed in to change notification settings - Fork 349
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Optional PR #152
base: master
Are you sure you want to change the base?
Optional PR #152
Conversation
@jsvine Per your suggestion I added my markovify Piano to the list of implementations/examples. Thanks. |
Thanks for the suggestion, @asigalov61. Could you explain more about (a) the motivation for using As far as I can tell, the standard
... but And on your piano example: Really fun, thanks! Could you, however, submit that as a separate PR? |
@jsvine Thank you for complimenting my work. It means a lot to me. I will submit a separate PR with the link. Thank you. As far as the secrets module goes... while the standard random module is decent and fits fine with your implementation, it is always a good idea to use a more random and more secure version of the random generator. Not only it is a best practice but it would also help to reduce Markov plagiarism and repetitions as it can do it under certain circumstances. In general, using the secrets random should produce better results (both for text and music from my direct experience). Otherwise, you are correct, and the standard random module is probably fine to use too. Although if I were you I would advise the users about it and let them know about the plagiarism/repetitions possibilities. As a note, in AI music, plagiarism and repetitions are a huge issue and this is where secrets.random helps, so I make my suggestion from this particular perspective. So using secrets may not be critical/needed for other purposes. I hope this makes sense. Thanks. |
Great, thanks!
As I understand it, That said, I'm open to being convinced otherwise. If you or someone else can point me to documentation that demonstrates |
@jsvine Apologies for the delayed response. I sorta missed your last response... Yes, I agree that difference between secrets and standard random is not that big perceptually so I am not saying that it will offer a significant improvement. However, from my understanding, secrets.random uses crypto algos + oher tricks to not only make it as random as possible, but also it provides a much better random distribution, which is quite similar to how AI models do it, which is why I suggested looking into it. I will try to make an example for you if I can to show how and where it is different, but please give me some time as it is not a priority issue for both of us. And thank you very much again for hearing my suggestions and for making this awesome markov-chain implementation. Much much appreciated. Alex. PS. I was even able to generate multi-instrumental music with markovify. Check it out here if you are curious. Thanks. |
@jsvine Btw, I wanted to kindly ask you to add my Markovify Piano to your list, please because for the love of God I can't figure out how to make a separate pull request for README. I still can't figure out GitHub PRs so your help will be much appreciated. Or, if you can tell me how to do it, it would be great too but I think it is just easier to add manually IMHO. Thank you. Here is the code:
|
No problem, now done: b0bfd2a |
@jsvine Thank you very much for your help and for the great software. If you need any help or want to share something, do not hesitate to contact me. Would be happy to help in return. Alex |
I think replacing regular random with secrets.random should improve the generating pattern/uniqueness of the pattern.
These are just my humble suggestions and it is totally up to you guys... :)