[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [HTCondor-users] More job transform questions



Hi Jeff,

 

I think that the problem is that a list must be enclosed in curly brackets. Can be seen e.g. with:

 

$ classad_eval 's="a, b"' 'split(s)'

[ s = "a, b" ]

{ "a","b" }

 

As for the transform debugging, here is an example for your case:

 

$ cat /tmp/ad

RequestCpus = 4

RequestMemory = 5000

 

$ cat /tmp/rules

CLCoreEquiv = max({ MY.RequestCpus, int(MY.RequestMemory / 4096) })

EVALSET Arlo $(CLCoreEquiv)

 

$ condor_transform_ads -rules /tmp/rules /tmp/ad

Arlo = 4

RequestCpus = 4

RequestMemory = 5000

 

 

Hope this helps.

 

Cheers,

    Antonio

 

 

From: HTCondor-users <htcondor-users-bounces@xxxxxxxxxxx> On Behalf Of Jeff Templon
Sent: Wednesday, 5 February 2025 13:32
To: HTCondor-Users Mail List <htcondor-users@xxxxxxxxxxx>
Subject: [HTCondor-users] More job transform questions

 

Hi,

 

Why does this not work, inside a job transform?

 

# these don't work like I'd expect

CLCoreEquiv = max([ MY.RequestCpus, int(MY.RequestMemory / 4096) ])

EVALSET Arlo $(CLCoreEquiv)

 

 

The name âArloâ has no significance, itâs a result of trying to boil the problem down to the smallest reproducible bit.  I saw elsewhere, int used as $INT, Iâve never seen âmaxâ used in the docs for the transform, however âjoinâ works fine, which would lead me to expect that âmaxâ would work and âintâ as well.  The documentation is ârather sketchyâ on these details AFAICT.

 

Iâd appreciate any pointers, as well as a concrete, working example of how to use the transform debugging tool (the docs are rather sketchy on those details as well).

 

J âWhereâs SketchUp Pro when you need itâ T