2dollarsim

joined 2 years ago
MODERATOR OF
[–] 2dollarsim 1 points 2 years ago* (last edited 2 years ago) (1 children)

You now need to get a <10 second wav file as an example to train from. Apparently as little as 4 seconds works too. I won't cover that in this tutorial.

For mine, I cut some audio from a clip of a woman speaking with very little background noise. You can use https://www.lalal.ai/ to extract voice from background noise, but I didn't need to do that in this case. I did when using a clip of Megabyte from Reboot talking, which worked.. mostly well.

I created an input folder to put my training wav file in:

bark-with-voice-clone/input

Now we can go through this next section of the tutorial:

Run Jupyter Notebook while in the bark folder:

jupyter notebook

This will open a new browser tab wit the Jupyter interface. Click on clone_voice.ipynb

This is very similar to Google Collab where you run blocks of code. Click on the first block of code and click Run. If the code block has a “[*]” next to it, then it is still processing, just give it a minute to finish.

This will take a while and download a bunch of stuff.

If it manages to finish without errors, run blocks 2 and 3. In block 4, change the line to: filepath = “input/audio.wav”

Make sure you update this block with a valid filepath (to prevent a permissions related error remove the leading “/”) and audio name

outputs will be found in: bark\assets\prompts

[–] 2dollarsim 1 points 2 years ago* (last edited 2 years ago) (2 children)

Now for a tricky part:

When I tried to run through voice cloning, I had this error:

--> 153 def auto_train(data_path, save_path='model.pth', load_model: str | None = None, save_epochs=1):

154 data_x, data_y = [], []

156 if load_model and os.path.isfile(load_model):

TypeError: unsupported operand type(s) for |: 'type' and 'NoneType'

From file customtokenizer.py in directory bark-with-voice-clone/hubert/

To solve this, I just plugged this error into chatGPT and made some slight modifications to the code.

At the top I added the import for Union underneath the other imports:

from typing import Union

And at line 154 (153 before adding the import above), I modified it as instructed:

def auto_train(data_path, save_path='model.pth', load_model: Union[str, None] = None, save_epochs=1):

compare to original line:

def auto_train(data_path, save_path='model.pth', load_model: str | None = None, save_epochs=1):

And that solved the issue, we should be ready to go!

[–] 2dollarsim 1 points 2 years ago (3 children)

Now all the components should be installed. Note that I did not need to install numpy or torch as described in the original post

You can test that it works by running

jupyter notebook

And you should get an interface like this pop up in your default browser:

[–] 2dollarsim 2 points 2 years ago (4 children)

Disclaimer I'm using linux, but the same general steps should apply to windows as well

First, create a venv so we keep everything isolated:

python3.9 -m venv bark-with-voice-clone/

Yes, this requires ** python 3.9 ** it will not work with python 11

cd bark-with-voice-clone

source bin/activate

pip install .

When this completes:

pip install jupyterlab

pip install notebook

I needed to install more than what was listed in the original post, as each time I ran the notebook it would mention another missing thing. This is due to the original user alrady having these components installed, but since we are using a virtual environment, these extras will be required:

Pip install the below:

soundfile

ipywidgets

fairseq

audiolm_pytorch

tensorboardX

[–] 2dollarsim 2 points 2 years ago* (last edited 2 years ago)

There's a community here for LLMs: [email protected]

[–] 2dollarsim 1 points 2 years ago

Yeah, I often have those dreams where I'm out of place and being judged by everyone who has agreed to be wierd

[–] 2dollarsim 4 points 2 years ago

Some of these were absolute gold.. I'm happy to see these coming back!

[–] 2dollarsim 17 points 2 years ago

It's kind of awesome we are having these problems really.

[–] 2dollarsim 3 points 2 years ago

Goddammit why did you have to say that. Now I can't just gobble everyone's movie popcorn.

[–] 2dollarsim 1 points 2 years ago (1 children)

I would agree, but the rate of innovation in AI is so unpredictable that it could go either way.

[–] 2dollarsim 22 points 2 years ago (3 children)

I saw an image comparing these with the older versions, and while the size of the vehicle has massively increased, the size of the actual tray has decreased.

[–] 2dollarsim 1 points 2 years ago (4 children)

Haha it won't be a joke next week when the new text-to-video model comes out

1
AI news this week (www.youtube.com)
submitted 2 years ago* (last edited 2 years ago) by 2dollarsim to c/oobabooga
 

Would be nice to hear from people who suffer from this condition who also have ADHD..

How do you relax?

How do you switch your mind off at night?

How do you motivate yourself to do those tasks that you really don't want to do?

How do you not focus 110%/25 hours a day on the latest obsession?

Do you also have a caffeine and/or nicotine / alcohol addiction?

 

Tested it myself, huge improvement!

2
First post (self.oobabooga)
submitted 2 years ago by 2dollarsim to c/oobabooga
 

I'll try post as much good content here as possible to get it started

 

Part 1: I was with friends discussing a book that we all enjoyed. Then I was in a house, and I realised that the book was connected to the house. A deep tunnel was being dug, to find something. We were going to find the tunnel. I walked into the other room to light the fire. I picked up the piece of coal to put in the fireplace. It was shaped like the head of an animal. It appeared to be possessed by some malevolent spirit. People were worried about the spirit, but I was antagonistic, and went hunting to find it. Then I can remember entering a large concrete building. A big hairy creature was standing at an opening, trying to fix some clockwork mechanism with chains. He complained that I had made things difficult for him, the chains weren't aligning. He then finally got a large weight attached to a chain to an opening, and let it go, and it started dragging the chains as it slid out.

Part 2: I went outside, and saw the chains had started to pull a surface of lead out. I was on top of a long concrete slope, but now the surface was covered in lead. It was like fast flowing liquid metal, except it was solid. I could walk on it, but every second it was changing, appearing to be a river of metal. I enjoyed running down the slope, and up the sides of the walls as the metal flowed over them. I reached the bottom, and was with 2 people: my brother and our close friend. We followed a river until we came to a dam made of terraced stone blocks. It was quite well made, and obviously for people to enjoy walking beside. But we had noticed that the river had been flowing towards the dam, and from the pool at the bottom, small trickles were running up the hill to the top of the dam. My friend commented that 'if you found water that behaved that way, wouldn't you build something to try to stop it?' And it seemed this new fancy stone dam was built on top of an ancient structure.

Part 3: We continued walking and at the top of the dam we were in a forest. I split off from the group and noticed in the trees, there were hanging bunches of raspberries. I ate one, and it was delicious. I yelled to the others to try them too, and then noticed that all sorts of different delicious looking berries were hanging down, some even looked and tasted like gummy worms. And then I found the book on the ground, that I mentioned earlier. Things seemed very bad. I ran back over to my friend, who was then acting crazy, and was trying to eat a plastic bag. He tried to brush me off when I tried to get him to stop. I grabbed him by his head and I could see his eyes didn't look right. I told him "I love you bro, I wouldn't be telling you to do this if it wasn't deadly serious. You have to snap out of it. trust me!" And he seemed to understand, and took the plastic out of his mouth.

Part 4: Then we walked out of the forest and found ourselves in a room, like a small cafe with windows where we could see the street. Me and my brother were there, and our friend was seated at a table, with a collection of odd things arranged in a specific way. Things like, stones, leaves, half a walnut shell. And there was a woman, she had black hair. She said "and now the last part. A close friend makes 2 brothers realise they have betrayed each other." and the friend moved two objects on the table into different positions. "it's done." he said. And then I realised, that this has all happened before. We had been manipulated again into completing their ritual.

Final part:

I started to cry and panic a bit, and I yelled at the two of them: "We have been trying to escape but they keep bringing us back here!" The woman told my brother and my friend, "It's not a good idea to look at the sky." But I knew what was there, and I told the other 2 they should look and see for themselves. Outside the world had changed, there was different technology, strange vehicles, and people dressed very differently. Covering most of the sky above us, there was a huge eye, surrounded by dark brown fur. It was watching the world, while everyone tried to avoid it's gaze. And as I looked out the window, moving just enough to glimpse the edge of the eye, I knew I didn't want it to see me.

view more: ‹ prev next ›