Skip to content

Conversation

@beasteers
Copy link
Collaborator

@beasteers beasteers commented Apr 8, 2024

Currently, details about rooms and their data structures live inside the Scaper object including some adhoc handling of directory structures. Moving this out should make it easier to implement things like virtual rooms in the API.

Changes:

  • SOFARoom class
    • SOFARoom.get_ambient_noise_paths formerly Scaper.use_room_ambient_noise
      • returns a list of paths instead of sampling inside the function
      • fixed minor bug which would have returned incorrect files if you were in a folder like foa_experiments
    • SOFARoom.get_irs formerly Scaper.get_room_irs_wav_xyz
      • calls SOFARoom._format_irs formerly Scaper.get_format_irs (disable format=False)
    • SOFARoom.get_positions formerly Scaper.get_room_irs_xyz
    • SOFARoom.get_boundaries formerly Scaper._get_room_min_max
  • BaseRoom added as a generic base class. May just change to Room?
  • Scaper
    • added Scaper.room: SOFARoom
    • rir_dir, room:str, format are now under SOFARoom
    • use_room_ambient_noise=True moved from Scaper.__init__ to Scaper.add_background
      • I know add_background is only intended to be run once, but I figured this would make it possible to layer ambient noise with noise generators

This is just a sketch, so feel free to discuss alterations. This PR should all be structural so the audio outputs should stay exactly the same.

I have generated some test files successfully, but my FSD50K download is only partial right now (for some reason).

@beasteers beasteers requested a review from ChrisIck April 20, 2024 00:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants