I recently visited a website which promised to tell me what I should do as a career. I figured this out long ago, but was still interested in what the result would be. I'll leave it to the reader's imagination as to whether the result is accurate...
This description is a generalisation. If it rings true, you've found your career type.
You would be very happy in a career that utilised your level-headedness, and allowed you to work mainly on your own. You want a career that allows you to be creative, without having to be involved with lots of people. Some careers that would be perfect for you are:
Artist
Historian
Banker
Novelist
University Professor
Photographer
Vet
Paralegal
Graphic Designer
Online Content Developer
Webmaster
Producer
Managing Director
Nutritionist
Advertising
Nursing
You like working and being alone. You like to avoid attention at all costs. You tend to keep to yourself, and not interact much with the people around you. You enjoy spending time with a few a close friends. You like to listen to others, but don't like sharing much about yourself. You are very quiet and private.
You are very practical, and only act after thinking things through. You don't like being forced to answer quickly. You have to evaluate the situation completely. You make decisions based on what you can verify with your senses.
You like to be deeply involved in one or two special projects. You like to be behind the scenes. You are very logical and fair. You feel you should be honest with others and protect their feelings.
You trust your gut instincts. You are easily inspired and trust that inspiration. You are very innovative. You analyse things by looking at the big picture. You are concerned about how what you do affects others. You worry about your actions and the future. You tend to use a lot of metaphors and are very descriptive and colourful in your choice of language.
You are very creative, and get bored easily if you don't get to express yourself. You like to learn new things. You don't like the same old routine. You like to leave your options open.
Finding a career that is right for you isn't always an easy thing. However, if you secure a job that is suited to your personality type you will enjoy going to work, feel great about yourself, feel appreciated and look forward to what's ahead.
This test was adapted from C. G. Jung's famous personality types.
Read more: What career will suit your personality? | iVillage UK http://www.ivillage.co.uk/what-career-will-suit-your-personality/121527#ixzz2TMqw4Wpu
Parenting: Information & advice
Monday, 20 May 2013
Tuesday, 14 May 2013
A punch to the stomach, a palm to the head
Two things stood out from tonight's Wing Chun class:
1. Forget all notion of a martial art if you need to fight.
2. It is better to use an open palm to the head of an opponent than a punch.
Both concepts were things that I had already assumed, so it was quite satisfying to have them confirmed by someone with many more years of experience in martial arts. Through uneven numbers, I had the chance to train with the instructor (Sifu in Chinese, but we never use that term). Being told that he trusted my level of control enough for me to target his centre was high praise indeed.
The principle of forgetting knowledge of a martial art was something I overheard. One of the relatively new members was discussing sparring, to which the instructor replied that the movements of Wing Chun must be practised as often as possible, so they are an automatic response to a threat, but concentrating on correct form and rigidly sticking to Wing Chun will cause momentary brain freeze. It is true. It's one thing I have always believed. Worrying about correct technique will probably cost someone a fight, and the potential consequences of that are permanent injury or death. Anything which removes the threat is good.
It wasn't until the end of the class that I got to ask a question about the Wing Chun forms. I noticed that I have a tendency to strike with my palm if I am striking anything above the height of my own shoulder, and that particular idiosyncrasy seems to be unique in the class. My training regime, as far as Wing Chun is concerned, concentrates on the first two empty hand forms, and I had noticed that the forms tend to follow my tendency to hit low with the fist and high with an open hand. Apparently, my impression that all high strikes are open handed is correct, and that is by design. I will leave it to the reader to form their own opinion on why the forms are designed in such a way.
If you practise any other martial art, I hope this has been useful to you too.
1. Forget all notion of a martial art if you need to fight.
2. It is better to use an open palm to the head of an opponent than a punch.
Both concepts were things that I had already assumed, so it was quite satisfying to have them confirmed by someone with many more years of experience in martial arts. Through uneven numbers, I had the chance to train with the instructor (Sifu in Chinese, but we never use that term). Being told that he trusted my level of control enough for me to target his centre was high praise indeed.
The principle of forgetting knowledge of a martial art was something I overheard. One of the relatively new members was discussing sparring, to which the instructor replied that the movements of Wing Chun must be practised as often as possible, so they are an automatic response to a threat, but concentrating on correct form and rigidly sticking to Wing Chun will cause momentary brain freeze. It is true. It's one thing I have always believed. Worrying about correct technique will probably cost someone a fight, and the potential consequences of that are permanent injury or death. Anything which removes the threat is good.
It wasn't until the end of the class that I got to ask a question about the Wing Chun forms. I noticed that I have a tendency to strike with my palm if I am striking anything above the height of my own shoulder, and that particular idiosyncrasy seems to be unique in the class. My training regime, as far as Wing Chun is concerned, concentrates on the first two empty hand forms, and I had noticed that the forms tend to follow my tendency to hit low with the fist and high with an open hand. Apparently, my impression that all high strikes are open handed is correct, and that is by design. I will leave it to the reader to form their own opinion on why the forms are designed in such a way.
If you practise any other martial art, I hope this has been useful to you too.
Sunday, 12 May 2013
I know nothing
I tend not to comment on YouTube or any martial arts sites now. In the past, when I have, a reply has come from someone who casts doubt on my experience in Wing Chun, though they helpfully go on to show that it is they who know nothing of Wing Chun.
It's something I have been contemplating recently. Using the principle that the most effective weapon is that which remains concealed until needed, I'm actually happy when my Wing Chun experience is doubted. Furthermore, those who feel free to comment on Wing Chun, having only read briefly about the art or watched videos online, are doing the art a service indirectly: those who are foolish enough to take their word will never understand Wing Chun. Here is a good example of what I am talking about...
"Chi Sau is one of the very few ways to beat an opponent that is faster than you besides blind luck. Just because you dont know how to slow your opponents down using it doesnt mean its wrong. Someone who doesnt believe in touch sensitivity (which is much faster and accurate than eye) reaction probably doesn't know what it is even if they claim to be a student."
First of all, it contains the loaded "just because you don't know" and "claim to be a student", which hint at the work of an internet troll trying to provoke a reaction - an evaluation given further credence by the fact that I said nothing about "touch sensitivity" in the comment which prompted the reaction. What he is referring to is the contact reflex, a term with which he would be familiar, if he were a student of Wing Chun.
It starts badly and continues from there, really. Chi Sau is not a way to beat an opponent that is faster than you. Actually, you will never directly use Chi Sau in a combat situation: it is simply a way of training responses which have been developed using the aforementioned contact reflex. Reaction times amongst humans also vary little so, if you are truly faced with someone who is faster than you are, they are superhuman and you should have run away while you had the chance.
I don't know how to slow down an opponent using Chi Sau? I hold my hands up on this one. If anyone can show me a clip of someone being slowed down by Chi Sau, I will say that some supernatural power is at work. Again, Chi Sau is not fighting: it trains responses through the use of developing a contact reflex. The only sure way to slow down an opponent, apart from compliant training partners in a martial arts class, is to hit them repeatedly in order to effect functional impairment. My own take on this is that a responsible human being will use only the force that is necessary.
"Someone who doesn't believe in touch sensitivity"? It's the wrong terminology. If I didn't believe in the sensitivity of my touch, I would constantly be knocking things over or dropping them. What he means is the contact reflex, which is so fundamental to Wing Chun that it would be lunacy to train Wing Chun if I really did not believe in it. It is faster and more accurate than the eye? No, it isn't. We react more slowly to what we see. If our hand was on fire, it would take us a while to connect the sight of our hand on fire to the concept of our hand being on fire, whereas our brain is wired to recognise pain instantly. The eye is not slower, but our reaction to what we see is slower than our reaction to what we feel.
As for me "claiming" to be a student of Wing Chun, there is no effective way to prove my experience as a student over the internet. Given all the problems with my accuser's comment, however, I would venture that he has never taken part in a genuine Wing Chun class or, if he has, clearly it has not been understood by him or explained in a way he understands. To think that I am wrong about his lack of experience, even for one moment, is truly horrifying. The reply came a year after my original comment, so was rendered unnecessary by the passing of time, and also shows a lack of respect that is truly unwelcome within the martial arts community (but is disappointingly common on YouTube).
The best comment I ever saw on a YouTube video stated that some people on YouTube believe themselves to be an expert in every martial art on the planet. I can't remember who originally made that comment, but full credit to them. The teenage boys, hyped up from watching UFC in their bedrooms or on their phones, usually lack the courage to actually attend a martial arts class, so insulting genuine martial artists from a safe distance passes for courage in their minds.
So, if I am being judged against the Wing Chun that these people know, I am happy to say that I know nothing of it.
It's something I have been contemplating recently. Using the principle that the most effective weapon is that which remains concealed until needed, I'm actually happy when my Wing Chun experience is doubted. Furthermore, those who feel free to comment on Wing Chun, having only read briefly about the art or watched videos online, are doing the art a service indirectly: those who are foolish enough to take their word will never understand Wing Chun. Here is a good example of what I am talking about...
"Chi Sau is one of the very few ways to beat an opponent that is faster than you besides blind luck. Just because you dont know how to slow your opponents down using it doesnt mean its wrong. Someone who doesnt believe in touch sensitivity (which is much faster and accurate than eye) reaction probably doesn't know what it is even if they claim to be a student."
First of all, it contains the loaded "just because you don't know" and "claim to be a student", which hint at the work of an internet troll trying to provoke a reaction - an evaluation given further credence by the fact that I said nothing about "touch sensitivity" in the comment which prompted the reaction. What he is referring to is the contact reflex, a term with which he would be familiar, if he were a student of Wing Chun.
It starts badly and continues from there, really. Chi Sau is not a way to beat an opponent that is faster than you. Actually, you will never directly use Chi Sau in a combat situation: it is simply a way of training responses which have been developed using the aforementioned contact reflex. Reaction times amongst humans also vary little so, if you are truly faced with someone who is faster than you are, they are superhuman and you should have run away while you had the chance.
I don't know how to slow down an opponent using Chi Sau? I hold my hands up on this one. If anyone can show me a clip of someone being slowed down by Chi Sau, I will say that some supernatural power is at work. Again, Chi Sau is not fighting: it trains responses through the use of developing a contact reflex. The only sure way to slow down an opponent, apart from compliant training partners in a martial arts class, is to hit them repeatedly in order to effect functional impairment. My own take on this is that a responsible human being will use only the force that is necessary.
"Someone who doesn't believe in touch sensitivity"? It's the wrong terminology. If I didn't believe in the sensitivity of my touch, I would constantly be knocking things over or dropping them. What he means is the contact reflex, which is so fundamental to Wing Chun that it would be lunacy to train Wing Chun if I really did not believe in it. It is faster and more accurate than the eye? No, it isn't. We react more slowly to what we see. If our hand was on fire, it would take us a while to connect the sight of our hand on fire to the concept of our hand being on fire, whereas our brain is wired to recognise pain instantly. The eye is not slower, but our reaction to what we see is slower than our reaction to what we feel.
As for me "claiming" to be a student of Wing Chun, there is no effective way to prove my experience as a student over the internet. Given all the problems with my accuser's comment, however, I would venture that he has never taken part in a genuine Wing Chun class or, if he has, clearly it has not been understood by him or explained in a way he understands. To think that I am wrong about his lack of experience, even for one moment, is truly horrifying. The reply came a year after my original comment, so was rendered unnecessary by the passing of time, and also shows a lack of respect that is truly unwelcome within the martial arts community (but is disappointingly common on YouTube).
The best comment I ever saw on a YouTube video stated that some people on YouTube believe themselves to be an expert in every martial art on the planet. I can't remember who originally made that comment, but full credit to them. The teenage boys, hyped up from watching UFC in their bedrooms or on their phones, usually lack the courage to actually attend a martial arts class, so insulting genuine martial artists from a safe distance passes for courage in their minds.
So, if I am being judged against the Wing Chun that these people know, I am happy to say that I know nothing of it.
Tuesday, 23 April 2013
Zen
When something troubles me, I go for a walk. I don't know whether it is the exercise, being outside or something deeper and more spiritual, but it enables me to think more clearly about what is troubling me. A friend of mine recently asked about the connection between Zen Buddhism and martial arts. With the best will in the world, it is not an easy connection to explain. However, I started to think about the link for the first time in a while, and that is what is troubling me right now.
This weekend, there is a Wing Chun seminar, hosted by the head of our Wing Chun organisation. The knowledge he is imparting there - techniques in chi sau and the wooden dummy - are valuable to understanding Wing Chun. With this in mind, it's somewhat surprising that I decided not to go.
Within some branches of the combat arts, there is a hidden agenda. Many of these arts were developed by Zen masters and, besides teaching skills in armed and unarmed combat, there is the subtext of a philosophical element. Some practitioners will spend years perfecting physical techniques, and never understand the spiritual side of what they practise: others will grasp it almost immediately.
In most of the martial arts classes I have attended, there has been something of a macho attitude, somewhat out of step with the Zen underpinnings of the art being taught. In the Wing Chun class, I have detected such an attitude beginning to creep in. The students discuss fights they have had in the outside world; some spar (wearing protective pads, of course) and hit each other too hard. Most disturbingly for me, even the relatively new students are now exaggerating, in their own minds, the knowledge they have of the art they practise, and becoming somewhat arrogant in their manner.
Unfortunately,Wing Chun is certainly not alone in this, though the nature of Wing Chun certainly makes it more vulnerable to the macho attitude. That which came originally from another culture is necessarily influenced by the culture within which it is practised. The martial arts, particularly in the age of cage fighting, are losing their connection with Zen. In a culture that is gradually losing its connection with all that is sacred and spiritual, it is hardly surprising. Due to the efforts of Ip Man and his students throughout the world in making it a practical fighting art, Wing Chun already had a very loose connection with its spiritual past. Maybe Wing Chun is better for that.
I can't pinpoint the moment where Zen entered my perspective on the martial arts, or life in general. I have a feeling it was when I was reading martial arts magazines some years ago, looking at various arts and the philosophy behind them.
So, what am I left with now? When I attend my Wing Chun class, I am simply learning to fight. There may be brief moments when a deeper understanding comes, but they are few and far between. Rather than the physical techniques leading me to Zen, it is Zen that is now leading me to physical techniques. I believe that is what they call having come full circle. Is it necessary for me to learn more physical techniques? That is what I am struggling with right now, along with the thought that maybe arts with no spiritual subtext teach more in the way of pure combative skill. If I am now able to bring Zen to everything I do, surely I can bring it to any form of art?
It may take time, but an answer will come.
This weekend, there is a Wing Chun seminar, hosted by the head of our Wing Chun organisation. The knowledge he is imparting there - techniques in chi sau and the wooden dummy - are valuable to understanding Wing Chun. With this in mind, it's somewhat surprising that I decided not to go.
Within some branches of the combat arts, there is a hidden agenda. Many of these arts were developed by Zen masters and, besides teaching skills in armed and unarmed combat, there is the subtext of a philosophical element. Some practitioners will spend years perfecting physical techniques, and never understand the spiritual side of what they practise: others will grasp it almost immediately.
In most of the martial arts classes I have attended, there has been something of a macho attitude, somewhat out of step with the Zen underpinnings of the art being taught. In the Wing Chun class, I have detected such an attitude beginning to creep in. The students discuss fights they have had in the outside world; some spar (wearing protective pads, of course) and hit each other too hard. Most disturbingly for me, even the relatively new students are now exaggerating, in their own minds, the knowledge they have of the art they practise, and becoming somewhat arrogant in their manner.
Unfortunately,Wing Chun is certainly not alone in this, though the nature of Wing Chun certainly makes it more vulnerable to the macho attitude. That which came originally from another culture is necessarily influenced by the culture within which it is practised. The martial arts, particularly in the age of cage fighting, are losing their connection with Zen. In a culture that is gradually losing its connection with all that is sacred and spiritual, it is hardly surprising. Due to the efforts of Ip Man and his students throughout the world in making it a practical fighting art, Wing Chun already had a very loose connection with its spiritual past. Maybe Wing Chun is better for that.
I can't pinpoint the moment where Zen entered my perspective on the martial arts, or life in general. I have a feeling it was when I was reading martial arts magazines some years ago, looking at various arts and the philosophy behind them.
So, what am I left with now? When I attend my Wing Chun class, I am simply learning to fight. There may be brief moments when a deeper understanding comes, but they are few and far between. Rather than the physical techniques leading me to Zen, it is Zen that is now leading me to physical techniques. I believe that is what they call having come full circle. Is it necessary for me to learn more physical techniques? That is what I am struggling with right now, along with the thought that maybe arts with no spiritual subtext teach more in the way of pure combative skill. If I am now able to bring Zen to everything I do, surely I can bring it to any form of art?
It may take time, but an answer will come.
To the trolls
“The difference between genius and stupidity is genius has its limits.” ~Albert Einstein
Much as I would like to say I hate internet trolls, I feel sorry for them. I really do. I'm not suggesting for a moment that they are not a nuisance, but that is also all they will ever be - a minor irritation. Of more concern is their apparent lack of self-awareness. If you dare to point out that they are a troll, you will find that they appear to take a great deal of offence at what they see as an unwarranted slur on their character. The truth is that awareness of what they are wounds them deeply, as it would be too awful to acknowledge the depths to which they have sunk. The likelihood is that they will already have said far worse things to many people, so let's try to understand where they are coming from.
Internet trolls tend to be teenage boys, or anyone who has the mindset of a teenage boy. Worse, they are often so isolated and lonely that an argument on an online forum, or comment stream is, to them, the only meaningful social interaction they have during their day. Yes, they probably have family, but we must question whether these are the kind of people who would fit well into a family unit, let alone be loved and wanted by their families. Imagine how empty your life would have to be before you would consider spending your days sitting by your computer, endlessly searching the forums and comments for a chance to say something deliberately contentious or, more often, to insult someone by calling them an idiot or some deeply offensive euphemism for male homosexuality.
The internet, you see, is something of a safe haven. Safe from the playground bullies, wilfully ignoring all reasonable admonishment, they feel able to express views that, often, they don't actually hold. Strange though it may seem, going against their core beliefs is a small price to pay for gaining some reply from an actual living person. Sadly, it is possible that they have no core beliefs, and believe in nothing, so they have to pretend. Remember, most of these people are male, and spend a great deal of their time visiting pornographic web sites, sitting by their computers with a box of tissues at the ready: they can only dream about getting physically intimate with a real woman, or man, or farmyard animal. The assumed persona of internet troll gives these individuals a temporary release from their own existence, from the depressing reality of who they truly are.
Some have replied to the comments of the trolls. Much as I think it's wrong, I also understand it. They may feel ashamed to be insulted by someone of such inferior intelligence, and may be all too aware that the trolls feel each "win" validates their existence. It must be kept in mind, however, that these poor unfortunates are only acting out what they only wish they could do in reality. We all know that doing it within the relatively safe confines of the internet is cowardly beyond contempt, but we must refrain from reacting to them. The worst thing we can do is allow them to feel like the righteous crusaders of their fantasies, keeping the internet free of all intelligent discourse and opinion, bringing it down to the level of pre-school jibes and counter jibes, with which they are more comfortable. Just as it is often impossible to reason with pre-school children, it is also impossible to reason with internet trolls. Their sense of reason and logic has become warped by the internet being their only source of social interaction.
Wider society has been unfair to the internet troll. Their meaningless existence, devoid of friendship, love or respect, has embittered them. The rest of the world becomes, in their tiny minds, the enemy. It is all too easy for them to blame their situation on those with more fulfilling lives. Maybe if we stop giving them what they want on the forums and comment streams, they will leave their computers and find that there is another world outside of their limited experience.
Much as I would like to say I hate internet trolls, I feel sorry for them. I really do. I'm not suggesting for a moment that they are not a nuisance, but that is also all they will ever be - a minor irritation. Of more concern is their apparent lack of self-awareness. If you dare to point out that they are a troll, you will find that they appear to take a great deal of offence at what they see as an unwarranted slur on their character. The truth is that awareness of what they are wounds them deeply, as it would be too awful to acknowledge the depths to which they have sunk. The likelihood is that they will already have said far worse things to many people, so let's try to understand where they are coming from.
Internet trolls tend to be teenage boys, or anyone who has the mindset of a teenage boy. Worse, they are often so isolated and lonely that an argument on an online forum, or comment stream is, to them, the only meaningful social interaction they have during their day. Yes, they probably have family, but we must question whether these are the kind of people who would fit well into a family unit, let alone be loved and wanted by their families. Imagine how empty your life would have to be before you would consider spending your days sitting by your computer, endlessly searching the forums and comments for a chance to say something deliberately contentious or, more often, to insult someone by calling them an idiot or some deeply offensive euphemism for male homosexuality.
The internet, you see, is something of a safe haven. Safe from the playground bullies, wilfully ignoring all reasonable admonishment, they feel able to express views that, often, they don't actually hold. Strange though it may seem, going against their core beliefs is a small price to pay for gaining some reply from an actual living person. Sadly, it is possible that they have no core beliefs, and believe in nothing, so they have to pretend. Remember, most of these people are male, and spend a great deal of their time visiting pornographic web sites, sitting by their computers with a box of tissues at the ready: they can only dream about getting physically intimate with a real woman, or man, or farmyard animal. The assumed persona of internet troll gives these individuals a temporary release from their own existence, from the depressing reality of who they truly are.
Some have replied to the comments of the trolls. Much as I think it's wrong, I also understand it. They may feel ashamed to be insulted by someone of such inferior intelligence, and may be all too aware that the trolls feel each "win" validates their existence. It must be kept in mind, however, that these poor unfortunates are only acting out what they only wish they could do in reality. We all know that doing it within the relatively safe confines of the internet is cowardly beyond contempt, but we must refrain from reacting to them. The worst thing we can do is allow them to feel like the righteous crusaders of their fantasies, keeping the internet free of all intelligent discourse and opinion, bringing it down to the level of pre-school jibes and counter jibes, with which they are more comfortable. Just as it is often impossible to reason with pre-school children, it is also impossible to reason with internet trolls. Their sense of reason and logic has become warped by the internet being their only source of social interaction.
Wider society has been unfair to the internet troll. Their meaningless existence, devoid of friendship, love or respect, has embittered them. The rest of the world becomes, in their tiny minds, the enemy. It is all too easy for them to blame their situation on those with more fulfilling lives. Maybe if we stop giving them what they want on the forums and comment streams, they will leave their computers and find that there is another world outside of their limited experience.
Monday, 18 March 2013
Making an MP3 CD in Linux
Sometimes it is difficult to be an open source enthusiast. Alongside my enthusiasm for free and open source software, I am also a fan of high quality audio. To me, it makes little sense to store my music in any format other than ogg vorbis files: apart from FLAC and other lossless formats, which consume too much hard disk space for a music collection as vast as mine, vorbis has, to my ears, the best sound quality.
The problem is that my portable music player does not recognise vorbis files, nor does the CD player in my car. The common thread between them (the portable music player recognises FLAC and MP3, the car CD player WMA and MP3) is support for MP3 files.
The way I chose to do this is to create a directory/folder into which I place ogg files, so that they may be converted to MP3. This folder is then maintained by deleting songs with which I am bored, and adding new songs that I would want to take wherever I go.
The important thing is not to cut and paste the songs into the folder, because we want to delete the original vorbis files, as our player does not support them. So, we want to copy the files into the folder, rather than move them, and delete vorbis files that take up space unnecessarily. Please bear this in mind when using the BASH script below, as I can't take any responsibility for losses arising from the use of this script. I merely share this here because it works for me. If you can make it work better, please feel free to create your own modified version.
With that in mind, here is the BASH script...
#!/bin/bash
mp3encoder=$(lame --version | grep "(http://www.mp3dev.org/)")
chmod +w *.ogg
chmod +w *.flac
for f in *.flac; do
oggenc -q10 "$f" && rm "$f"
done
for f in *.ogg; do
songartist=$(vorbiscomment -l "$f" | grep -i '\<ARTIST=' | head --lines=1 - | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
songtitle=$(vorbiscomment -l "$f" | grep -i '\<TITLE=' | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
songalbum=$(vorbiscomment -l "$f" | grep -i '\<ALBUM=' | head --lines=1 - | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
songnumber=$(vorbiscomment -l "$f" | grep -i '\<TRACKNUMBER=' | cut --delimiter="=" --fields=2-)
songyear=$(vorbiscomment -l "$f" | grep -i '\<DATE=' | cut --delimiter="=" --fields=2-)
songgenre=$(vorbiscomment -l "$f" | grep -i '\<GENRE=' | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
albumartist=$(vorbiscomment -l "$f" | grep -i '\<ALBUMARTIST=' | head --lines=1 - | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
#decode the ogg to a wav file
sox -S --norm "$f" -r 44100 "${f%%ogg}wav"
#normalize, while keeping as much dynamic range as possible
normalize-audio -a -12dBFS -l -6dBFS "${f%%ogg}wav"
normalize-audio -a -12dBFS -l -6dBFS "${f%%ogg}wav"
normalize-audio -a -12dBFS -l -6dBFS "${f%%ogg}wav"
#show the vorbis tags
vorbiscomment -l "$f" && rm "$f"
#create the MP3 with optimal settings for listening in car
echo ""
echo "Encoding $songtitle, by $songartist from $songalbum ($albumartist)"
echo ""
lame -q 0 -V 5 --strictly-enforce-ISO --add-id3v2 --clipdetect --ta "$songartist" --tt "$songtitle" --tl "$songalbum" --tn "$songnumber" --ty "$songyear" --tv "TENC=$mp3encoder" --tv "TPE2=$albumartist" --tg "$songgenre" "${f%%ogg}wav" "${f%%ogg}mp3" && rm "${f%%ogg}wav"
#clean up
newname=$(echo "$songartist - $songtitle" | tr '/?: .' '-_-__')
mv -f "${f%%ogg}mp3" "$newname.mp3"
unset songartist
unset songtitle
unset songalbum
unset songnumber
unset songyear
unset songgenre
unset albumartist
done
mp3gain -r -k -p -s i *.mp3
mp3total=0
for f in *.mp3; do
songtitle=$(soxi "$f" | grep "\<Title=" | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
songartist=$(soxi "$f" | grep "\<Artist=" | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
mv "$f" "$songartist - $songtitle.mp3"
done
for f in *.mp3; do
mp3total=`echo $(($mp3total+1))`
done
echo ""
echo "This directory contains $mp3total MP3s, making a total of "$(ls -l -h | grep total | cut --characters 7-)""
echo "Brasero says our target size is 702M for a CD-R"
echo "Smallest file in this directory is "$(ls -S | tail --lines=1)""
echo "Largest file in this directory is "$(ls -S | head --lines=1)""
echo ""
Let's go through what's happening here. First of all, we copy the string identifying our version of LAME into a variable, for pasting into an ID3 field later. I've noticed that MP3 files created with iTunes have this field set, so why not our files created with LAME? We then "chmod +w" our files, just in case some of them have the read only flag set. Next, we convert any FLAC files, if we have them, into ogg vorbis format, so that the script can work on one type of file from this point.
The FOR loop in the next section steps through every ogg file in the folder, and performs the conversion, starting with a bunch of statements which obtain vorbis tags, via vorbiscomment, format them correctly, and store them in variables that we will use later to tag our MP3 file. Next, we decode the ogg file to a WAV file, so that any modifications can be performed losslessly at this stage. You will notice that the SOX line contains a normalisation filter and sets the sample frequency to 44100Hz (CD quality). Sometimes, the conversion process creates clipping artefacts, which we don't want, so the --norm filter checks the file during conversion and sets a limiter to ensure this isn't happening. Setting each file to a sample rate of 44100Hz is also sensible, because I have downloaded files in the past which have strange sample rates and 44.1kHz files are likely to play on just about any device.
Next, we come to something which is very important for collections of this nature. We don't want to be adjusting the volume level between songs, especially while driving, so we need a way of getting them to a similar volume. A setting of -12dB from full scale, and a hard limit of -6dB from full scale is the default for the normalize-audio program, and it's a sensible setting. Modern CDs, from those I have tested, have an average setting of -8dBFS and a limiter of -3dBFS, if one is used at all! Apparently, this phenomenon is known as the "loudness wars", where each record label is trying to produce louder and louder discs. It's idiotic, because it requires the heavy-handed use of a compression filter, so each part of the music is at a similar volume - distortion creeps in, sound quality suffers, and the listening experience is generally unpleasant, especially when listening for prolonged periods. Until record companies and studios can be convinced to go back to a time when dynamic range (the difference between the soft and loud parts of a recording) was more important than outright loudness, at least reducing the overall volume of the recording will help matters a little.
It is arguable that adding a low pass and high pass filter to the earlier SOX command is acceptable, and perhaps desirable, for portable listening or in-car environments. In theory, this would lead to the volume being more level between recordings, as the frequency response is more uniform. My personal thought on this, as an audio enthusiast, is that I want to modify the audio characteristics of the recording as little as possible, and the normalisation process seems to work to an acceptable standard without low pass or high pass filters being used.
After printing a string which contains the name of the song, artist and album, so that we know the tags have been transferred correctly, we get onto the business of encoding the MP3. I have used a variable bit rate setting of 5, which equates to around 128kbps, but you can set a constant bit rate of 128kbps by changing "-V 5" to "-b 128" or any other of the allowable bit rates. Variable bit rate will render an MP3 file of better quality than a constant bit rate file, though there are still players which do not correctly decode VBR MP3s. When this process is complete, we remove the WAV file.
To finish, we rename the MP3 to a sensible standard format, unset variables in preparation for the next file and run every MP3 file in the folder through mp3gain (just in case we added files which were already in MP3 format, or we need replaygain information to be added). When our files are converted, the script displays a total size for the MP3s in the folder, so that we know whether they will fill our device or go beyond the storage space we have available.
I hope this script may prove useful, if only to introduce the reader to some principles of BASH scripting. If you can improve upon it, or want to modify it to your own requirements, please do so. When I have the time to improve upon my BASH skills, I will probably make my own modifications.
The problem is that my portable music player does not recognise vorbis files, nor does the CD player in my car. The common thread between them (the portable music player recognises FLAC and MP3, the car CD player WMA and MP3) is support for MP3 files.
The way I chose to do this is to create a directory/folder into which I place ogg files, so that they may be converted to MP3. This folder is then maintained by deleting songs with which I am bored, and adding new songs that I would want to take wherever I go.
The important thing is not to cut and paste the songs into the folder, because we want to delete the original vorbis files, as our player does not support them. So, we want to copy the files into the folder, rather than move them, and delete vorbis files that take up space unnecessarily. Please bear this in mind when using the BASH script below, as I can't take any responsibility for losses arising from the use of this script. I merely share this here because it works for me. If you can make it work better, please feel free to create your own modified version.
With that in mind, here is the BASH script...
#!/bin/bash
mp3encoder=$(lame --version | grep "(http://www.mp3dev.org/)")
chmod +w *.ogg
chmod +w *.flac
for f in *.flac; do
oggenc -q10 "$f" && rm "$f"
done
for f in *.ogg; do
songartist=$(vorbiscomment -l "$f" | grep -i '\<ARTIST=' | head --lines=1 - | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
songtitle=$(vorbiscomment -l "$f" | grep -i '\<TITLE=' | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
songalbum=$(vorbiscomment -l "$f" | grep -i '\<ALBUM=' | head --lines=1 - | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
songnumber=$(vorbiscomment -l "$f" | grep -i '\<TRACKNUMBER=' | cut --delimiter="=" --fields=2-)
songyear=$(vorbiscomment -l "$f" | grep -i '\<DATE=' | cut --delimiter="=" --fields=2-)
songgenre=$(vorbiscomment -l "$f" | grep -i '\<GENRE=' | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
albumartist=$(vorbiscomment -l "$f" | grep -i '\<ALBUMARTIST=' | head --lines=1 - | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
#decode the ogg to a wav file
sox -S --norm "$f" -r 44100 "${f%%ogg}wav"
#normalize, while keeping as much dynamic range as possible
normalize-audio -a -12dBFS -l -6dBFS "${f%%ogg}wav"
normalize-audio -a -12dBFS -l -6dBFS "${f%%ogg}wav"
normalize-audio -a -12dBFS -l -6dBFS "${f%%ogg}wav"
#show the vorbis tags
vorbiscomment -l "$f" && rm "$f"
#create the MP3 with optimal settings for listening in car
echo ""
echo "Encoding $songtitle, by $songartist from $songalbum ($albumartist)"
echo ""
lame -q 0 -V 5 --strictly-enforce-ISO --add-id3v2 --clipdetect --ta "$songartist" --tt "$songtitle" --tl "$songalbum" --tn "$songnumber" --ty "$songyear" --tv "TENC=$mp3encoder" --tv "TPE2=$albumartist" --tg "$songgenre" "${f%%ogg}wav" "${f%%ogg}mp3" && rm "${f%%ogg}wav"
#clean up
newname=$(echo "$songartist - $songtitle" | tr '/?: .' '-_-__')
mv -f "${f%%ogg}mp3" "$newname.mp3"
unset songartist
unset songtitle
unset songalbum
unset songnumber
unset songyear
unset songgenre
unset albumartist
done
mp3gain -r -k -p -s i *.mp3
mp3total=0
for f in *.mp3; do
songtitle=$(soxi "$f" | grep "\<Title=" | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
songartist=$(soxi "$f" | grep "\<Artist=" | cut --delimiter="=" --fields=2- | iconv --from-code=UTF-8)
mv "$f" "$songartist - $songtitle.mp3"
done
for f in *.mp3; do
mp3total=`echo $(($mp3total+1))`
done
echo ""
echo "This directory contains $mp3total MP3s, making a total of "$(ls -l -h | grep total | cut --characters 7-)""
echo "Brasero says our target size is 702M for a CD-R"
echo "Smallest file in this directory is "$(ls -S | tail --lines=1)""
echo "Largest file in this directory is "$(ls -S | head --lines=1)""
echo ""
Let's go through what's happening here. First of all, we copy the string identifying our version of LAME into a variable, for pasting into an ID3 field later. I've noticed that MP3 files created with iTunes have this field set, so why not our files created with LAME? We then "chmod +w" our files, just in case some of them have the read only flag set. Next, we convert any FLAC files, if we have them, into ogg vorbis format, so that the script can work on one type of file from this point.
The FOR loop in the next section steps through every ogg file in the folder, and performs the conversion, starting with a bunch of statements which obtain vorbis tags, via vorbiscomment, format them correctly, and store them in variables that we will use later to tag our MP3 file. Next, we decode the ogg file to a WAV file, so that any modifications can be performed losslessly at this stage. You will notice that the SOX line contains a normalisation filter and sets the sample frequency to 44100Hz (CD quality). Sometimes, the conversion process creates clipping artefacts, which we don't want, so the --norm filter checks the file during conversion and sets a limiter to ensure this isn't happening. Setting each file to a sample rate of 44100Hz is also sensible, because I have downloaded files in the past which have strange sample rates and 44.1kHz files are likely to play on just about any device.
Next, we come to something which is very important for collections of this nature. We don't want to be adjusting the volume level between songs, especially while driving, so we need a way of getting them to a similar volume. A setting of -12dB from full scale, and a hard limit of -6dB from full scale is the default for the normalize-audio program, and it's a sensible setting. Modern CDs, from those I have tested, have an average setting of -8dBFS and a limiter of -3dBFS, if one is used at all! Apparently, this phenomenon is known as the "loudness wars", where each record label is trying to produce louder and louder discs. It's idiotic, because it requires the heavy-handed use of a compression filter, so each part of the music is at a similar volume - distortion creeps in, sound quality suffers, and the listening experience is generally unpleasant, especially when listening for prolonged periods. Until record companies and studios can be convinced to go back to a time when dynamic range (the difference between the soft and loud parts of a recording) was more important than outright loudness, at least reducing the overall volume of the recording will help matters a little.
It is arguable that adding a low pass and high pass filter to the earlier SOX command is acceptable, and perhaps desirable, for portable listening or in-car environments. In theory, this would lead to the volume being more level between recordings, as the frequency response is more uniform. My personal thought on this, as an audio enthusiast, is that I want to modify the audio characteristics of the recording as little as possible, and the normalisation process seems to work to an acceptable standard without low pass or high pass filters being used.
After printing a string which contains the name of the song, artist and album, so that we know the tags have been transferred correctly, we get onto the business of encoding the MP3. I have used a variable bit rate setting of 5, which equates to around 128kbps, but you can set a constant bit rate of 128kbps by changing "-V 5" to "-b 128" or any other of the allowable bit rates. Variable bit rate will render an MP3 file of better quality than a constant bit rate file, though there are still players which do not correctly decode VBR MP3s. When this process is complete, we remove the WAV file.
To finish, we rename the MP3 to a sensible standard format, unset variables in preparation for the next file and run every MP3 file in the folder through mp3gain (just in case we added files which were already in MP3 format, or we need replaygain information to be added). When our files are converted, the script displays a total size for the MP3s in the folder, so that we know whether they will fill our device or go beyond the storage space we have available.
I hope this script may prove useful, if only to introduce the reader to some principles of BASH scripting. If you can improve upon it, or want to modify it to your own requirements, please do so. When I have the time to improve upon my BASH skills, I will probably make my own modifications.
Friday, 15 March 2013
Friendship
It's difficult to
define friendship. Maybe a friend is simply someone who sees your value
as a human being - who values you not for what you can do for them, but
for who you are with them. They will have the courage to tell you when
you have done wrong, but will forgive you for it. Likewise, they will
take great pleasure in hearing about the things that have gone well for
you.
Of course, there is also your best friend. You may be lucky enough to have more than one best friend. This is someone who knows you better than anyone, because you would trust them not to reveal your secrets. For many of us involved in a romantic love, this is our chosen partner.
It is often said that friends made over the internet and social networking sites are not true friends. Is physical proximity the best measure of friendship? No. The measure of friendship is its ability to stand the test of time and the numerous problems that will affect any close relationship, even those with family members. A true friend may not always be there when you need them - they may have other demands on their time - but, when they are able to help, there is no one better placed to do so.
If you have good friends, take a moment each day to think of what that means. It means that you are valued, and that people take pleasure in your company. Let them know that they are appreciated. Be quick to settle any differences. To lose a friend is to lose something very valuable indeed.
Of course, there is also your best friend. You may be lucky enough to have more than one best friend. This is someone who knows you better than anyone, because you would trust them not to reveal your secrets. For many of us involved in a romantic love, this is our chosen partner.
It is often said that friends made over the internet and social networking sites are not true friends. Is physical proximity the best measure of friendship? No. The measure of friendship is its ability to stand the test of time and the numerous problems that will affect any close relationship, even those with family members. A true friend may not always be there when you need them - they may have other demands on their time - but, when they are able to help, there is no one better placed to do so.
If you have good friends, take a moment each day to think of what that means. It means that you are valued, and that people take pleasure in your company. Let them know that they are appreciated. Be quick to settle any differences. To lose a friend is to lose something very valuable indeed.
Subscribe to:
Posts (Atom)