SWIFTSIM / emulator

The SWIFT simulation cosmological emulator (swift-emulator)
GNU Lesser General Public License v3.0
5 stars 2 forks source link

[JOSS review] small fixes in Interaction with SWIFT examples #37

Closed kstoreyf closed 2 years ago

kstoreyf commented 2 years ago

Part of JOSS review.

Hello, I was running the example code for the Interaction with SWIFT examples and hit a few small bugs / things that could be more self-consistent.

  1. On the [Experimental Design]((https://swiftemulator.readthedocs.io/en/latest/swift_io/design.html) page, in the last code block,

I believe key: output_path / f"{key}.yml" should be something like key: f"{output_path}/{key}.yml" ?

Just saw that this was referenced in #34 but I don't think it has been fixed.

  1. For the example on Loading SWIFT Data, it uses the load_pipeline_outputs function without importing it on the page. It would be good to include the line from swiftemulator.io.swift import load_pipeline_outputs

  2. Similarly, in the last code block on Loading SWIFT Data, replace emulator = GaussianProcessEmulator() with

    from swiftemulator.emulators import gaussian_process
    emulator = gaussian_process.GaussianProcessEmulator()

Thanks!

Moyoxkit commented 2 years ago

Thanks for the comments, will be fixed with #40

kstoreyf commented 2 years ago

Thanks! For 3, I think you now need to call gaussian_process.GaussianProcessEmulator(), not just GaussianProcessEmulator(), after the import statement.

Moyoxkit commented 2 years ago

Yes indeed, has been fixed now