Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • getdp getdp
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 57
    • Issues 57
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • getdpgetdp
  • getdpgetdp
  • Merge requests
  • !85

Draft: Trying to send Tables (PostOperation) via ONELAB (as a string)

  • Review changes

  • Download
  • Email patches
  • Plain diff
Closed Nicolas Marsic requested to merge SimpleTableOnelab into master May 12, 2021
  • Overview 1
  • Commits 1
  • Pipelines 1
  • Changes 1

Hi Christophe,

I was wondering if there is a way to send a SimpleTable (and co.) via ONELAB with a PostOperation? I tried a simple

Print[bPhiM, OnGrid ..., File ..., Format SimpleTable, SendToServer "Output/bPhiM"];

but it doesn't work... am I missing something?

If I'm not, I looked a bit in the code, and hacked Kernel/Pos_Format.cpp...

I basically changed Tabular_PrintElement such that the table is printed in a string (in addition to the old PostStream) line-by-line.

With this string, I can send the lines of the tables via Message::AddOnelabStringChoice (by mimicking the case PE->NbrNodes == 1 && PSO_P->Format != FORMAT_NODE_TABLE && PSO_P->Format != FORMAT_ELEMENT_TABLE).

In the end, I have a ONELAB string with different choices, each of them being a line of the table, and I can get it back in python via c.getStringChoices.

We could also parse back the numbers in the string and send onelab::number instead of onelab::string, but I don't know if we can safely parse %.16g in a systematic way?

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: SimpleTableOnelab