sc::DistShellPair(3)

πŸ“¦
version 2.3.1 Β· 4 versions
, in ubuntu jammy

πŸ’… sc::DistShellPair β€” the manual page, but make it make sense

okay bestie, so this is sc::DistShellPair, and it lives in the MPQC manual (section 3, the library-call girlies ✨). Short version: it hands out shell pairs to your tasks, either statically or dynamically. That's the whole vibe. Now let's get into it 🫢


✨ NAME ✨

sc::DistShellPair β€” distributes shell pairs either statically or dynamically. no cap, that's literally the job πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

#include <distshpair.h>

πŸŽ€ Classes πŸŽ€

  • class SharedData β€” this is where you stash the data that has to be shared between all the cooperating shell pairs. it's giving group project energy, but like, the functional kind 🌸

⭐ Public Member Functions ⭐

  • DistShellPair (const Ref< MessageGrp > &, int nthread, int mythread, const Ref< ThreadLock > &lock, const Ref< GaussianBasisSet > &bs1, const Ref< GaussianBasisSet > &bs2, bool dynamic, SharedData *shared=0) β€” the constructor, and honestly the main character of this whole page. the DistShellPair class is used to distribute shell pair indices among tasks πŸ”₯
  • void init () β€” resets to the first shell pair. a fresh start, a clean slate, we love a reset era πŸ’–
  • void set_debug (int d) β€” how much stuff to print out. turn it up if you're nosy (me, I'm nosy) πŸ™ˆ
  • void set_print_percent (double p) β€” how often to print status from node 0 πŸ‘‘
  • int get_task (int &P, int &Q) β€” puts the current PQ shell pair into P and Q and returns 1. more on this below, it's got lore πŸ’€

🌈 Detailed Description 🌈

Distributes shell pairs either statically or dynamically. that's it, that's the whole thesis. two modes, one class, slay ✨


πŸ’œ Constructor & Destructor Documentation πŸ’œ

sc::DistShellPair::DistShellPair (const Ref< MessageGrp > &, int nthread, int mythread, const Ref< ThreadLock > & lock, const Ref< GaussianBasisSet > & bs1, const Ref< GaussianBasisSet > & bs2, bool dynamic, SharedData * shared = 0)

The DistShellPair class is used to distribute shell pair indices among tasks. Both static (round-robin) and dynamic methods are supported. so like, you can take turns politely (round-robin) or you can do the dynamic thing where the work gets grabbed as it goes β€” both valid, both iconic πŸ¦‹


πŸ”₯ Member Function Documentation πŸ”₯

int sc::DistShellPair::get_task (int & P, int & Q)

Puts the current PQ shell pair into P and Q and returns 1. when there are no more shell pairs to be processed by this processor, 0 is returned. so it's a 1 while there's still tea to spill, and a 0 when you're done, periodt πŸ’…

⚠️ okay important detail, don't skip this: once we start doing get_tasks, we have to go to the end if dynamic load balancing is used. no bailing halfway, that's the rule 😭

And the ownership breakdown, because it matters:

  • P belongs to bs1
  • Q belongs to bs2
  • if (bs1 == bs2) then P is greater or equal to Q

write that down, it's on the exam πŸ“


🧚 Author 🧚

Generated automatically by Doxygen for MPQC from the source code. so nobody hand-wrote this, the robot did it, and honestly? it ate πŸ€–βœ¨


okay that's the whole page bestie, you're officially caught up πŸ’–

πŸŽ€ sign-off time: this lil doc is from Version 2.3.1, dated Sun Oct 4 2020, and yeah, the copyright/license vibes belong to the MPQC project and the Doxygen-generated fine print. go forth and distribute those shell pairs, queen πŸ‘‘πŸŒΈ
πŸ“¦ where this page comes from