AccelBrainBeat is a Python library for creating the binaural beats or monaural beats. You can play these beats and generate wav files. The frequencys can be optionally selected.
Project description
AccelBrainBeat is a Python library for creating the binaural beats or monaural beats. You can play these beats and generate wav files. The frequencys can be optionally selected.
Description
This Python script enables you to handle your mind state by a kind of “Brain-Wave Controller” which is generally known as Biaural beat or Monauarl beats in a simplified method.
Documentation
Full documentation is available on https://code.accel-brain.com/Binaural-Beat-and-Monaural-Beat-with-python/ . This document contains information on functionally reusability, functional scalability and functional extensibility.
Demonstration IN Movie
Drive to design the brain’s level upper (Youtube)
Installation
Install using pip:
pip install AccelBrainBeat
Source code
The source code is currently hosted on GitHub.
Python package index(PyPI)
Binary installers for the latest released version are available at the Python package index.
Dependencies
NumPy: v1.7.0 or higher
To play the beats on console
If you want to not only output wav files but also play the beats on console, PyAudio (v0.2.9 or higher) must be installed.
Use-case on console
You can study or work while listening to the Binaural or Monauarl beats. Before starting your job, run a batch program on console.
Create “Binaural Beat” and output wav file
Run the batch program: save_binaural_beat.py.
python bat/save_binaural_beat.py -o binaural_beat.wav -l 400 -r 430 -t 60 -v 0.01
The command line arguments is as follows.
python bat/save_binaural_beat.py -h
usage: save_binaural_beat.py [-h] [-o OUTPUT_FILE_NAME] [-l LEFT] [-r RIGHT] [-t TIME] [-v VOLUME] Create the Binaural Beat and save wav file. optional arguments: -h, --help show this help message and exit -o OUTPUT_FILE_NAME, --output_file_name OUTPUT_FILE_NAME Output file name. -l LEFT, --left LEFT Left frequencys (Hz). -r RIGHT, --right RIGHT Right frequencys (Hz). -t TIME, --time TIME Play time. This is per seconds. -v VOLUME, --volume VOLUME Sound volume.
Create “Monaural Beat” and output wav file
Run the batch program: save_monaural_beat.py.
python bat/save_monaural_beat.py -o monaural_beat.wav -l 400 -r 430 -t 60 -v 0.01
The command line arguments is as follows.
python bat/save_monaural_beat.py -h
usage: save_monaural_beat.py [-h] [-o OUTPUT_FILE_NAME] [-l LEFT] [-r RIGHT] [-t TIME] [-v VOLUME] Create the Monaural Beat and save wav file. optional arguments: -h, --help show this help message and exit -o OUTPUT_FILE_NAME, --output_file_name OUTPUT_FILE_NAME Output file name. -l LEFT, --left LEFT Left frequencys (Hz). -r RIGHT, --right RIGHT Right frequencys (Hz). -t TIME, --time TIME Play time. This is per seconds. -v VOLUME, --volume VOLUME Sound volume.
Create and play “Binaural Beat” on console
Run the batch program: play_binaural_beat.py.
python play_binaural_beat.py -l 400 -r 430 -t 60 -v 0.01
The command line arguments is as follows.
python bat/play_binaural_beat.py -h
usage: play_binaural_beat.py [-h] [-l LEFT] [-r RIGHT] [-t TIME] [-v VOLUME] Create and play the Binaural Beat. optional arguments: -h, --help show this help message and exit -l LEFT, --left LEFT Left frequencys (Hz). -r RIGHT, --right RIGHT Right frequencys (Hz). -t TIME, --time TIME Play time. This is per seconds. -v VOLUME, --volume VOLUME Sound volume.
Create and play “Monaural Beat” on console
Run the batch program: play_monaural_beat.py.
python bat/play_monaural_beat_beat.py -l 400 -r 430 -t 60 -v 0.01
The command line arguments is as follows.
python bat/play_monaural_beat.py -h
usage: play_monaural_beat.py [-h] [-l LEFT] [-r RIGHT] [-t TIME] [-v VOLUME] Create and play the Monaural Beat. optional arguments: -h, --help show this help message and exit -l LEFT, --left LEFT Left frequencys (Hz). -r RIGHT, --right RIGHT Right frequencys (Hz). -t TIME, --time TIME Play time. This is per seconds. -v VOLUME, --volume VOLUME Sound volume.
Use-case for coding
You can use this library as a module by executing an import statement in your Python source file.
Create wav file of “Binaural Beat”
Call the method.
from AccelBrainBeat.brainbeat.binaural_beat import BinauralBeat
brain_beat = BinauralBeat() # for binaural beats.
brain_beat.save_beat(
output_file_name="save_binaural_beat.wav",
frequencys=(400, 430),
play_time=10,
volume=0.01
)
output_file_name is wav file name or path.
Create wav file of “Monaural Beat”
The interface of monaural beats is also same as the binaural beats.
from AccelBrainBeat.brainbeat.monaural_beat import MonauralBeat
brain_beat = MonauralBeat() # for monaural beats.
brain_beat.save_beat(
output_file_name="save_monaural_beat.wav",
frequencys=(400, 430),
play_time=10,
volume=0.01
)
Create and play “Binaural Beat”
For example, if 400 Hz was played in left ear and 430 Hz in the right, then the binaural beats would have a frequency of 30 Hz.
Import Python and Cython modules.
from AccelBrainBeat.brainbeat.binaural_beat import BinauralBeat
Instantiate objects and call the method.
brain_beat = BinauralBeat()
brain_beat.play_beat(
frequencys=(400, 430),
play_time=10,
volume=0.01
)
The type of frequencys is tuple. This is a pair of both frequencys.
play_time is playing times(per seconds).
volume is the sound volume. It depends on your environment.
Create and play “Monaural Beat”
The interface of monaural beats is same as the binaural beats. MonoauralBeat is functionally equivalent to BinauralBeat.
from AccelBrainBeat.brainbeat.monaural_beat import MonauralBeat
brain_beat = MonauralBeat()
brain_beat.play_beat(
frequencys=(400, 430),
play_time=10,
volume=0.01
)
Licence
More detail
The function of this library is inducing you to be extreme immersive mind state on the path to peak performance. You can handle your mind state by using this library which is able to control your brain waves by the binaural beats and the monaural beats.
Concept of Binaural beats and Monauarl beats
According to a popular theory, brain waves such as Delta, Theta, Alpha, Beta, and Gamma rhythms tend to be correlated with mind states. The delta waves(1-3 Hz) are regarded as the slowest brain waves that are typically produced during the deep stages of sleep. The theta waves(4-7 Hz) are offen induced by the meditative state or focusing the mind. The alpha waves(8-12 Hz) are associate with relaxed state. The beta waves(13-29 Hz) are normal waking consciousness. The Gamma waves(30-100 Hz) are the fastest of the brain waves and associated with peak concentration and the brain’s optimal frequency for cognitive functioning.
By a theory of the binaural beats, signals of two different frequencies from headphone or earphone are presented separately, one to each ear, your brain detects the phase variation between the frequencies and tries to reconcile that difference. The effect on the brain waves depends on the difference in frequencies of each tone. For example, if 400 Hz was played in one ear and 430 in the other, then the binaural beats would have a frequency of 30 Hz.
The monaural beats are similar to the binaural beats. But they vary in distinct ways. The binaural beats seem to be “created” or perceived by cortical areas combining the two different frequencies. On the other hand, the monaural beats are due to direct stimulation of the basilar membrane. This makes it possible to hear the beats.
Please choose either binaural beets or monaural beats. If you set up 5 Hz, your brain waves and the frequency can be tuned and then you are able to be the meditative state or focusing the mind. Or what you choose to be relaxed state is the alpha waves(8-12 Hz).
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file AccelBrainBeat-1.0.5.tar.gz
.
File metadata
- Download URL: AccelBrainBeat-1.0.5.tar.gz
- Upload date:
- Size: 14.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fd724c3cb2aa835bc7c73054888af6abc701a1ef3629593246c7c7b12333cc13 |
|
MD5 | fa1d4892e870e26852be91385cef05ec |
|
BLAKE2b-256 | 09f3ea1aa5d6fe471b92e6f713c1017b484cbc6f01c8dc992ea0053be588c02f |
File details
Details for the file AccelBrainBeat-1.0.5-py3-none-any.whl
.
File metadata
- Download URL: AccelBrainBeat-1.0.5-py3-none-any.whl
- Upload date:
- Size: 16.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ee3333aeb32dac88f1b3912e36e625192bf0111403b7534fc1b53e477b0ddf52 |
|
MD5 | 04284c49aa64934c71771a7ff7e8e53b |
|
BLAKE2b-256 | 26e83329ff350821db14ffea7f0b8c97f2e5b8402508107574ddddc733ec447e |