Skip to main content

Scalable Agent-based GPU Enabled Simulator.

Project description

# SAGESim

Requirements

  • Python 3.11+
  • NVIDIA GPU with CUDA drivers or AMD GPU with ROCm 5.7.1+

Installation

Your system might require specific steps to installing mpi4py and/or cupy depending on your hardware. In that case use your systems recommended instructions to install mpi4py and cupy and execute:

pip install sagesim

Run Example

  • git clone https://code.ornl.gov/sagesim/sagesim
  • cd /path/to/clone_repo/examples/sir
  • mpirun -n 4 python run.py --num_agents 10000 --percent_init_connections 0.1 --num_nodes 1

There are some unfortunate quirks to using CuPyx jit.rawkernel:

  • nan checked by inequality to self. Unfortunate limitation of cupyx.
  • Dicts and objects are unsupported.
  • *args and **kwargs are unsupported.
  • nested functions are unsupported.
  • Be sure to use cupy data types and array routines in favor of numpy: [https://docs.cupy.dev/en/stable/reference/routines.html]
  • for loops must use range iterator only. No 'for each' style loops.
  • return does not seem to work well either
  • break and continue are unsupported!
  • Cannot reassign variables within if or for statements. Must be assigned at top level of function or new variable declared under subscope.
  • -1 indexing does not necessarily work as expected, as it will access the last element of the memory block of the array instead of the logical array. Use len(my_array) - 1 instead

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sagesim-0.4.0.dev1.tar.gz (21.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sagesim-0.4.0.dev1-py3-none-any.whl (26.7 kB view details)

Uploaded Python 3

File details

Details for the file sagesim-0.4.0.dev1.tar.gz.

File metadata

  • Download URL: sagesim-0.4.0.dev1.tar.gz
  • Upload date:
  • Size: 21.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.11

File hashes

Hashes for sagesim-0.4.0.dev1.tar.gz
Algorithm Hash digest
SHA256 ad41bc224631e35ff04bfb9dff9c111998412aacdf35a340a73e4690f94971ea
MD5 08861e9b357ce7cec16fa910ee47bae7
BLAKE2b-256 d12a224505aa4940b13e153704fc4a372aa4a0aead21a3ca828ebd8cc4f4e8cc

See more details on using hashes here.

File details

Details for the file sagesim-0.4.0.dev1-py3-none-any.whl.

File metadata

  • Download URL: sagesim-0.4.0.dev1-py3-none-any.whl
  • Upload date:
  • Size: 26.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.11

File hashes

Hashes for sagesim-0.4.0.dev1-py3-none-any.whl
Algorithm Hash digest
SHA256 4645b50a8034621b5eabde20f07bc3aa4eaca50b3bc3ef9dfe38ac9991700b2c
MD5 205f22409e2848cfed246a961025d474
BLAKE2b-256 af886cb89e7567767e6a818ee4c4d757b4d18ffb78fe3f6a06e5ab812792fcb5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page