[Swift-user] 0.94 to 0.95 Conversion
Mihael Hategan
hategan at mcs.anl.gov
Tue Jun 17 18:26:50 CDT 2014
Right. You need either filename(x) or @x. The "@" as in syntactic sugar
for "filename()" and the "@" as an annoying prefix to function names in
pre-0.95 are somewhat of a coincidence.
Mihael
On Tue, 2014-06-17 at 19:04 -0400, Matthew Shaxted wrote:
> Oh I believe I found the answer…
>
> The @’s needed to stay in front of the app variables in the below manner. I know they were removed for the functions (such as @arg), but apparently not so for the app file definitions. My app definition now looks like below:
>
> app (file json) runEP ( file imf, file epw, string params[] )
> {
> epLocal "--imf" @imf "--epw" @epw "--outall" "temp.tgz" "--outxml" "temp.xml" "--outjson" @json "--params" @params;
> }
>
> Thanks
>
> MATTHEW SHAXTED
>
> SKIDMORE, OWINGS & MERRILL LLP
> 224 South Michigan Ave.
> Chicago, IL 60604
> TEL: 312.360.4368
> FAX: 312.360.4545
> matthew.shaxted at som.com<mailto:matthew.shaxted at som.com>
>
> [cid:image001.png at 01CF8A56.92971870]
> WWW.SOM.COM<http://www.som.com/>
>
> The information contained in this communication may be confidential, is intended only for the use of the recipient(s) named above, and may be legally privileged. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this communication, or any of its contents, is strictly prohibited and may be unlawful. If you have received this communication in error, please return it to the sender immediately and delete the original message and any copy of it from your computer system. If you have any questions concerning this message, please contact the sender.
>
> [cid:image002.png at 01CF8A56.92971870]
>
> From: Matthew Shaxted
> Sent: Tuesday, June 17, 2014 6:00 PM
> To: 'David Kelly'
> Cc: 'swift-user at ci.uchicago.edu'; 'Yadu Nand'
> Subject: RE: 0.94 to 0.95 Conversion
>
> Another strange error when trying to convert my scripts from 0.94 to 0.95…
>
> I have an app defined in the swift script as below, and I’m getting an error: “Cannot pass type 'file' as a parameter to application 'epLocal' in application epLocal at line 8”.
>
> Did something change with app definition in 0.95 (ie cannot accept files?)?
>
> app (file json) runEP ( file imf, file epw, string params[] )
> {
> epLocal "--imf" imf "--epw" epw "--outall" "temp.tgz" "--outxml" "temp.xml" "--outjson" json "--params" params;
> }
>
> My generated apps file from swift.properties looks like below:
>
> coast epCoast /home/som/EnergyPlus/shanghai/RunAndReduceEP.sh
> local epLocal /home/som/EnergyPlus/shanghai/RunAndReduceEP.sh
>
>
> MATTHEW SHAXTED
>
> SKIDMORE, OWINGS & MERRILL LLP
> 224 South Michigan Ave.
> Chicago, IL 60604
> TEL: 312.360.4368
> FAX: 312.360.4545
> matthew.shaxted at som.com<mailto:matthew.shaxted at som.com>
>
> [cid:image001.png at 01CF8A56.92971870]
> WWW.SOM.COM<http://www.som.com/>
>
> The information contained in this communication may be confidential, is intended only for the use of the recipient(s) named above, and may be legally privileged. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this communication, or any of its contents, is strictly prohibited and may be unlawful. If you have received this communication in error, please return it to the sender immediately and delete the original message and any copy of it from your computer system. If you have any questions concerning this message, please contact the sender.
>
> [cid:image002.png at 01CF8A56.92971870]
>
> From: Matthew Shaxted
> Sent: Tuesday, June 17, 2014 5:04 PM
> To: 'David Kelly'
> Cc: swift-user at ci.uchicago.edu<mailto:swift-user at ci.uchicago.edu>
> Subject: RE: [Swift-user] Sites.xml to swift.properties Conversion
>
> Oh Great I just saw this now… this indeed works. Thanks the documentation was a bit misleading in section 4.8: http://swift-lang.org/guides/trunk/userguide/userguide.html#_location_of_swift_properties
>
> This is the sites.xml file I get now:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <config xmlns="http://www.ci.uchicago.edu/swift/SwiftSites">
>
> <pool handle="local">
> <filesystem provider="local"/>
> <profile namespace="globus" key="slots">1</profile>
> <profile namespace="karajan" key="jobThrottle">0.03</profile>
> <workdirectory>/home/som/EnergyPlus/test/work</workdirectory>
> <execution provider="coaster" jobmanager="local:local"/>
> <profile namespace="globus" key="jobsPerNode">8</profile>
> <profile namespace="globus" key="maxwalltime">00:15:00</profile>
> </pool>
>
> <pool handle="coaster">
> <profile namespace="globus" key="slots">1</profile>
> <profile namespace="globus" key="jobsPerNode">8</profile>
> <profile namespace="globus" key="maxwalltime">00:15:00</profile>
> <filesystem provider="local"/>
> <workdirectory>/home/som/EnergyPlus/test/work</workdirectory>
> <execution provider="coaster-persistent" jobmanager="local:local" url="http://localhost:56069"/>
> </pool>
>
> </config>
>
>
> MATTHEW SHAXTED
>
> SKIDMORE, OWINGS & MERRILL LLP
> 224 South Michigan Ave.
> Chicago, IL 60604
> TEL: 312.360.4368
> FAX: 312.360.4545
> matthew.shaxted at som.com<mailto:matthew.shaxted at som.com>
>
> [cid:image001.png at 01CF8A56.92971870]
> WWW.SOM.COM<http://www.som.com/>
>
> The information contained in this communication may be confidential, is intended only for the use of the recipient(s) named above, and may be legally privileged. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this communication, or any of its contents, is strictly prohibited and may be unlawful. If you have received this communication in error, please return it to the sender immediately and delete the original message and any copy of it from your computer system. If you have any questions concerning this message, please contact the sender.
>
> [cid:image002.png at 01CF8A56.92971870]
>
> From: David Kelly [mailto:davidkelly at uchicago.edu]
> Sent: Tuesday, June 17, 2014 4:46 PM
> To: Matthew Shaxted
> Cc: swift-user at ci.uchicago.edu<mailto:swift-user at ci.uchicago.edu>
> Subject: Re: [Swift-user] Sites.xml to swift.properties Conversion
>
> Hi Matthew,
>
> The new config assumes the provider is just 'coaster' by default, but it's possible to override this and specify your own url (just a little more verbose). This property should do it:
> jobManager=coaster-persistent:local:local:http://localhost:56069
> I'll make a note to add documentation about non-'coaster' setups in the userguide.
> David
>
> On Tue, Jun 17, 2014 at 4:03 PM, Matthew Shaxted <Matthew.Shaxted at som.com<mailto:Matthew.Shaxted at som.com>> wrote:
> Hi Swift support,
>
> I am in the process of converting my 0.94 swift scripts to 0.95, and I am having a bit of difficulties creating the correct sites properties from the new swift.properties file.
>
> I am trying to convert the sites.xml file below, and when I attempt to identify site.persistent-coaster{provider=”coaster-persistent”…} in the swift.properties file I am getting an “Error: Unknown property site.persistent-coasters.provider”.
>
> Can anyone please lend some insight on how to best convert from a sites.xml to a swift.properties file? I am using Swift 0.95 RC6 swift-r7900 cog-r3908
>
> Thanks,
> Matthew
>
>
> 0.94 Sites.xml File
>
> <config>
> <pool handle="localhost">
> <execution provider="coaster" jobmanager="local:local"/>
> <profile namespace="karajan" key="jobThrottle">0</profile>
> <profile namespace="karajan" key="initialScore">10000</profile>
> <filesystem provider="local"/>
> <workdirectory>{env.HOME}/work</workdirectory>
> </pool>
> <pool handle="persistent-coasters">
> <execution provider="coaster-persistent"
> url="http://localhost:56069"
> jobmanager="local:local"/>
> <profile namespace="globus" key="workerManager">passive</profile>
> <profile namespace="globus" key="jobsPerNode">2</profile>
> <profile key="jobThrottle" namespace="karajan">.01999</profile>
> <profile namespace="karajan" key="initialScore">10000</profile>
> <filesystem provider="local" url="none" />
> <workdirectory>/tmp/shaxted</workdirectory>
> </pool>
> </config>
>
>
> My new swift.properties file look like below:
>
> sitedir.keep=true
> wrapperlog.always.transfer=true
>
> site.local {
> tasksPerWorker=8
> taskWalltime=00:15:00
> maxJobs=1
> workdir=/home/som/EnergyPlus/test/work
> filesystem=local
> }
> app.local.echo=/bin/echo
> site=local
>
> site. persistent-coaster {
> provider=coaster
> tasksPerWorker=8
> taskWalltime=00:15:00
> maxJobs=2
> workdir=/home/som/EnergyPlus/test/work
> filesystem=local
> }
> app.persistent-coaster.echo=/bin/echo
> site=persistent-coaster
>
>
>
> MATTHEW SHAXTED
>
> SKIDMORE, OWINGS & MERRILL LLP
> 224 South Michigan Ave.
> Chicago, IL 60604
> TEL: 312.360.4368<tel:312.360.4368>
> FAX: 312.360.4545<tel:312.360.4545>
> matthew.shaxted at som.com<mailto:matthew.shaxted at som.com>
>
> [cid:image001.png at 01CF8A56.92971870]
> WWW.SOM.COM<http://www.som.com/>
>
> The information contained in this communication may be confidential, is intended only for the use of the recipient(s) named above, and may be legally privileged. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this communication, or any of its contents, is strictly prohibited and may be unlawful. If you have received this communication in error, please return it to the sender immediately and delete the original message and any copy of it from your computer system. If you have any questions concerning this message, please contact the sender.
>
> [cid:image002.png at 01CF8A56.92971870]
>
>
> _______________________________________________
> Swift-user mailing list
> Swift-user at ci.uchicago.edu<mailto:Swift-user at ci.uchicago.edu>
> https://lists.ci.uchicago.edu/cgi-bin/mailman/listinfo/swift-user
>
> _______________________________________________
> Swift-user mailing list
> Swift-user at ci.uchicago.edu
> https://lists.ci.uchicago.edu/cgi-bin/mailman/listinfo/swift-user
More information about the Swift-user
mailing list