[REL] Crew Chief v4.5 with rFactor 2 support

Discussion in 'Other' started by The Iron Wolf, Feb 1, 2017.

  1. mr_belowski

    mr_belowski Registered

    Joined:
    Feb 1, 2017
    Messages:
    122
    Likes Received:
    109
    The number sounds can't really have a proper inflection because they need to be usable in different contexts. The 'right' inflection is a combination of where they sit in a sentence (which is fixable by recording 3 or 4 versions of each number) but also the sounds immediately before and after then (real speech flows from one sound to the next - there are too many combinations for numbers so this isn't really fixable).

    Gianfranco worked very hard on creating differently inflected number sounds for the Italian sound pack, because in Italian inflection is really important for numbers. The app's number reading component does allow differently inflected sounds to be selected depending on where they are in the number.

    For English, it could be improved by adding different inflections like Gianfranco did, but it'll still sound a bit robotic. I'll do some experiments next week, see if I can get it a little more natural
     
    Alex72 and bravotangosix like this.
  2. bravotangosix

    bravotangosix Registered

    Joined:
    Nov 21, 2015
    Messages:
    265
    Likes Received:
    277
    Sounds like it's the best compromise. I don't for one minute take for granted the amount of work that I'm sure has gone into recording these sounds. I've done a fair bit of music recording myself over the years and know that it can be an endless road if left unchecked. Still a fantastic piece of work regardless. If it never changes I won't be any less impressed. :):)
     
  3. Alex72

    Alex72 Registered

    Joined:
    Dec 27, 2016
    Messages:
    1,196
    Likes Received:
    893
    Yeah indeed. Such a fantastic work guys. CrewChief is so naturally sounding compared to other spotters. I was blown away the first time i tested it in AC and equally blown away in AMS and now rF2. :) Incredible work. Thanks a lot to all involved.
     
    bravotangosix and jerrymcc like this.
  4. mr_belowski

    mr_belowski Registered

    Joined:
    Feb 1, 2017
    Messages:
    122
    Likes Received:
    109
    Having cogitated on this for a while, I think it would be easier to actually record all the number sounds as single files, so for 0-60 seconds there would be 600 sound files ("twenty one point seven", "twenty one point eight" and so on). That way I wouldn't have to fart about with inflection rules. It sounds like a lot of work, but I could use the same workflow I use for driver names so it's actually only a couple of hours. The hard part is making each recording sound right - it's really easy to slip into a 'counting' inflection, which sounds completely wrong. I'll have to concentrate :)

    I think adding a "one" or "two" to the start of the recording when announcing lap times would be a necessary compromise but would probably sound ok.

    Given that Vytautas has been working hard to sort out accuracy issues in the timing announcements, perhaps I should make then sound better. I'll see if it can squeeze it in for the next release
     
  5. Will Mazeo

    Will Mazeo Registered

    Joined:
    Sep 12, 2015
    Messages:
    1,971
    Likes Received:
    1,320
    Troll them mate, give Crew Chief a female AI "mind", that will be fun :D
     
  6. DaVeX

    DaVeX Registered

    Joined:
    Feb 7, 2015
    Messages:
    550
    Likes Received:
    557
    Sorry mr_b can you ask Gianfranco if he can translate all the base sounds you provided with the app?
    You did a great job but some (more) lines are missing (especially swearing) and I am forced to use the EN version (which I love too) because of this.
    Maybe if you ask him to do a correct 1:1 translation, he will do the job...also will be great if he can maintain the same file name with IT suffix, ex: name.wav > name_IT.wav because sometimes they have the same generic name and is difficult to understand which sound are used for what...
    I think you should sell this app and should sell language packs too...Is the best spotter I found and It covers every SIM on the market now, I think is time to evolve in something professional (and raise quality of translations too).
     
    Last edited: Feb 12, 2017
  7. BoothJoe

    BoothJoe Registered

    Joined:
    Oct 12, 2015
    Messages:
    202
    Likes Received:
    8
    ((Note, I realized after originally posting how dangerous a delete command that I employed could be, so I've provided an empty voice directory tree in the attached zip file instead of telling people to run that command. If you just have to know, google "how to delete all files of a certain type recursively in windows.))

    From the very start, understand that the folks who built CrewChief have NOT approved/blessed this approach.

    Here is a rundown on how to do your own voices. Note that these are text-to-speech voices. The state of tts at the moment, in my mind, is not as good as directly recording all of the comments. Voice inflection, emphasis, etc. just don't seem to be attainable. Just getting a good replication of EPSN's "C'mon, man, c'mon" is a particularly daunting task. Also, what we are doing here will replace all of the wav files in the original build of crewchief, so we start with an empty slate and build our own from scratch and then copy it over once we're satisfied with it (saving the original first, of course).

    The attached zip file contains everything you need except Python. It contains two free programs, balcon and sox, the python script to run everything, my voice.txt file (so you don't have to create it from scratch yourself) and a blank voice directory with all of the wav files deleted. Create a folder on your desktop called crewchief_audio and unzip/install balcon and sox into it. We're going to do all of our work in the crewchief_audio folder so this makes it simple to find everything we'll need without having to put in long path names. Put the voice folder, voice.py and voice.txt into it also.

    Using a text editor, open the voice.txt file I've included. This file contains all of the comments you want to use. Each comment goes on its own line. The format is main_folder\sub_folder\filename.wav:Audio that you want to hear. For example, here are a couple of lines from mine:

    acknowledge\deltasDisabled\1.wav:Okay, no more deltas
    acknowledge\deltasDisabled\2.wav:So you don't think you need deltas. Okay then.
    acknowledge\deltasEnabled\1.wav:We're going to start giving you deltas
    conditions\track_temp_increasing_its_now\1.wav:The track temp is increasing. It's now

    The lines can be in any order. The filenames are whatever you want them to be. In the sample above, the comment "Okay, no more deltas" will be recorded in a file called 1.wav, which will then be stored in the \voice\acknowledge\deltasDisabled folder.

    Once you have all your comments in the text file, it's time to run it. First, go into voice.py and change the "your_username" chunk to your Windows username. It will parse the file and do all the work. I use Python because I use Python. Someone with powershell experience could probably wrap up a version that wouldn't require python. If you don't have python, you'll have to install version 3 of it and you'll get the script to run with some variation of "python voice.py" depending on your installation of python. It's a "down and dirty" script that doesn't do any error checking, but it does everything in its own folder so there's no danger of it screwing up your original CrewChief if it fails.

    Basically, the script opens the voice.txt file and parses out the path and filename and the text that it will send to the tts engine. It uses balcon.exe to make the initial wav file using the default MS voice for your computer. Then it calls the sox program to apply some filters to the audio. You can play with some of these parameters to tune the audio to your taste. The silence command trims dead air space on the front and back of the clip. Highpass will give you the radio-style voice, and tempo speeds up the speech without making it go squeaky. The vol command, which needs to be run separately after everything else is done, increases the volume. Vol will clip, which makes the radio affect a touch better, in my opinion.

    Try out some of the wav files to make sure they are what you'd like (don't expect miracles). Once you are satisfied, go to the original CrewChiefV4 directory and rename the voice folder voice.org (we don't want to make a mess of it so put it aside so you can keep it pristine). Then copy the voice folder that you built from the crewchief_audio folder on your desktop to the CrewChiefV4 directory.

    Some notes: I THINK that if you name a clip/comment sweary_x.wav that it will only be used if you enable that feature in CrewChief preferences. There are other files in the original build with names other than x.wav. I don't know it they are important or not. But since you can give any comment any filename in the text file, you could match the existing names.

    It has not (I repeat, not) been extensively tested. It seems to work for me.

    It is NOT approved/blessed by the creators of CrewChief.
     

    Attached Files:

  8. jerrymcc

    jerrymcc Registered

    Joined:
    Oct 5, 2010
    Messages:
    160
    Likes Received:
    35
    Just thinking about the "spinning up" comments. It might be more useful to report the opposite ... "Your tires are slipping/scrubbing"? Similar to Trackmap, you would get a warning if you are scrubbing the tires into a corner or locking them while braking.
    Just a thought.

    Carry on, great addon.
     
  9. The Iron Wolf

    The Iron Wolf Member

    Joined:
    Feb 20, 2016
    Messages:
    896
    Likes Received:
    792
    Thanks for your inputs. I am not familiar with Trackmap, is it open source or is it still being actively maintained?

    In the next update of rF2 support in CC, spinning aspect will get better (@jeffcam already reported it works better). I wired the code to pick up wheel diameters from car class, so at the very least there will be GT and Kart diameters. And Jim is extending CC to allow vehicle classes to be configured using .json files. So, good stuff is coming :)
     
    bravotangosix likes this.
  10. mr_belowski

    mr_belowski Registered

    Joined:
    Feb 1, 2017
    Messages:
    122
    Likes Received:
    109
    This is correct. Files with names like "12_op_prefix_ok.wav" do change the behaviour of the app. They are used to mark some sound files as allowing (or requiring) a personalised component, and telling the app where to put this personalised component (for users that use the personalisations). In the above example, the app will occasionally prefix this sound with "OK [name], ..." - if the user didn't have the personalisations, the app would still use this sound without adding a personalisation. If it were called "12_rq_suffix_please.wav" the would suffix the sound with "..., please [name]" - if the user didn't have the personlisations the app with never use this sound (_op_ == optional personalisation, _rq_ = required personalisation, _suffix_ = play the sound then the personalisation, _prefix_ = play the personalisation then the sound).

    So it's possible to define which sounds the app will add personalisations to, whether they are added before or after the sound, which personalisation to select, and whether it's optional or required. You can also include the 'sweary' bit if this message is sweary - e.g.
    "sweary_15_op_prefix.wav". Note that the app will never select a sweary personalisation sound to combine with a sweary message - there's only ever 1 swearword in a message (it's a race engineer, not an Eddie Murphy gig)
     
    Last edited: Feb 13, 2017
  11. mr_belowski

    mr_belowski Registered

    Joined:
    Feb 1, 2017
    Messages:
    122
    Likes Received:
    109
    Also, a quick update on the timing messages. I recorded another batch of timing sounds yesterday - 1.0 up to 59.9 in 0.1 second increments (which requires a lot more concentration than you might think), plus another batch of sounds for 1.0 to 9.9 which also include "seconds" at the end. This makes all timing announcements from 1.0 to 59.9 'seamless' - there are no joins in the number part, which helps massively with the robotic sounding timing announcements. It didn't work so well when I added "1" or "2" in front of these new sounds to use in laptime announcements. So I'll do another batch which has single recordings for "one oh one" up to "two fifty nine" (1:01 to 2:59 - most laps fall into this range). Then I can add the "point 3" or whatever at the end of the new sounds for times > 59.9 seconds, so the join is between the minutes:seconds and the decimal point, rather than between the minutes and the seconds (which sounds really weird). I expect (hope...) this change to make the laptime reading sound quite natural.

    All this means another 120(ish) recordings to add to the 680 I did yesterday (!). But the result should be much nicer when it reads the gaps. Note that for 0.1 - 0.9 I already have separate recordings.

    All this and the associated code changes only apply to the English number reader - the Italian one is unchanged (but i do need to discuss it with Gianfranco).

    All this will be in the next version, which is shaping up to be a pretty major overhaul. I'm also looking at adding this new stuff to the Android app for Project Cars users.
     
  12. Will Mazeo

    Will Mazeo Registered

    Joined:
    Sep 12, 2015
    Messages:
    1,971
    Likes Received:
    1,320
    Someone make CC an official rF2 app and give these men a paycheck
     
    Alex72 and bravotangosix like this.
  13. Alex72

    Alex72 Registered

    Joined:
    Dec 27, 2016
    Messages:
    1,196
    Likes Received:
    893
    LOL! Backseat driver shouting at you that you are doing everything wrong? :D ;)
     
    The Iron Wolf likes this.
  14. DaVeX

    DaVeX Registered

    Joined:
    Feb 7, 2015
    Messages:
    550
    Likes Received:
    557
    No...shouting you to "slow down!Think to our childrens!"
     
    Alex72 likes this.
  15. jerrymcc

    jerrymcc Registered

    Joined:
    Oct 5, 2010
    Messages:
    160
    Likes Received:
    35
    FYI, Trackmap is an overlay display showing lots of parameters. It has a widget that shows which wheel and how much slippage that wheel has.

    My thought was that your "spinning" response might be changed to tell the driver if he is scrubbing the tires too much into a corner "pushing", etc., instead of the less useful and confusing "spinning" response.

    I'm sure trackmap is not open source and had been maintained until a year ago or so. I think some of the creators are still around but don't seem to be actively maintaining it ... it does have a few issues.

    Thanks again to you and mr bellows for all your effort.
     
  16. mr_belowski

    mr_belowski Registered

    Joined:
    Feb 1, 2017
    Messages:
    122
    Likes Received:
    109
    We're a bit limited here in what we can do with regard to "spinning". PCars (and Raceroom I think) send each wheel's rotational velocity, but they don't send slip angle data. So I have no way of knowing if the wheel is scrubbing / sliding, but I *can* tell if it's locked or spinning, so the app reports this. RF2 may offer more flexibility here but it'll be a longer term thing. Would you expect a race engineer to be warning you about high slip angles? I wasn't sure about the spinning / locking, but I guess that a grumpy engineer might berate his driver for tearing his tyres up
     
  17. Will Mazeo

    Will Mazeo Registered

    Joined:
    Sep 12, 2015
    Messages:
    1,971
    Likes Received:
    1,320
    I think a race engineer will complain if you use a curb you aren't supposed to :D
    But it's interesting that rF2 supports this but it's not possible to add the leds showing this in the cockpit like the Corvette GTE does in real life?
     
  18. The Iron Wolf

    The Iron Wolf Member

    Joined:
    Feb 20, 2016
    Messages:
    896
    Likes Received:
    792
    I am also a bit concerned about CC announcing too much information. In fact, in certain series telemetry during race is not allowed, so to some extent, even the fact that driver hears about tire temps is cheating. Of course, anything we do can be made optional, but I'd like to keep CC realistic, not an omnipresent alien.
     
    bravotangosix likes this.
  19. Will Mazeo

    Will Mazeo Registered

    Joined:
    Sep 12, 2015
    Messages:
    1,971
    Likes Received:
    1,320
    CC new name confirmed: God [is the] Chief will be it :D :D
     
  20. The Iron Wolf

    The Iron Wolf Member

    Joined:
    Feb 20, 2016
    Messages:
    896
    Likes Received:
    792
    ...thou shalt not brake too hard in this turn, my child... amen
     

Share This Page