Giter Club home page Giter Club logo

2023-mexico-scientific-programming-patterns's People

Contributors

lschwetlick avatar pberkes avatar

Watchers

 avatar  avatar

2023-mexico-scientific-programming-patterns's Issues

Exercise: Step 4 break out the next step probability

  • In a new module next_steps_proposals.py, write 2 functions for 2 different next step proposals: a Gaussian one (it's the one currently in the Walker code) and a square one (you can find an example in the exercise notebook)
  • Modify the constructor of Walker to take as arguments 1) a next_step_proposal function and 2) a next_step_proposal_arguments dictionary containing the arguments to pass to the function
  • Modify the notebook to run two simulations, one with the Gaussian proposal and one with the square proposal

Remember to reload the notebook kernel when you modify the code in you modules, as modules are cached during the first import and changes would not be visible.

Exercise: Step 3 break out the context map initialization

  • Move the context map initialization to 3 functions in a separate context_maps.py module
  • Modify the constructor of Walker to take a context_map array instead of a map_type
  • Modify the notebook to use the new code

Remember to reload the notebook kernel when you modify the code in you modules, as modules are cached during the first import and changes would not be visible.

Exercise: Step 5 reproducibility

  • Complete the run.py script
  • In the file, at the top we give the desired parameters for the run
  • Create a context map and walker (see previous exercises for reference)
  • Simulate a trajectory (see previous exercises for reference)
  • Save the trajectory using np.save(), and also save some metadata
  • Run the run.py script twice and confirm the results are identical by plotting them using the provided notebook

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.