|
jrunscript JavaScript built-ins | ||||||||
| PREV CLASS NEXT CLASS | |||||||||
| SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Object | +--GLOBALS
| Method Summary | |
<static> void
|
cat(obj, pattern)
Shows the content of a file, URL or InputStream |
<static> void
|
cd(target)
Changes the present working directory to the given directory |
<static> void
|
cp(from, to)
Copies a file, URL, or stream to another file or stream |
<static> void
|
date()
Prints the current date using the current locale |
<static> void
|
del(pathname)
A synonym for 'rm' |
<static> void
|
dir(d, filter)
A synonym for 'ls'. |
<static> Object
|
dirname(pathname)
Returns the directory part of a filename |
<static> void
|
echo(x)
Echoes the given string arguments |
<static> void
|
exec(cmd)
Execs a child process, waits for completion & returns exit code |
<static> void
|
exit(code)
Exit the shell program. |
<static> void
|
find(dir, pattern, callback)
Find in files. |
<static> void
|
grep(pattern, files )
Unix-like grep, but accepts JavaScript regex patterns |
<static> void
|
ip(name)
Prints the IP addresses of a given domain name |
<static> void
|
load(str)
Loads and evaluates JavaScript code from a stream, file, or URL |
<static> void
|
ls(dir, filter)
Lists the files in a directory |
<static> void
|
mkdir(dir)
Creates a new directory of a given name |
<static> void
|
mkdirs(dir)
Creates a directory, including any necessary but nonexistent parent directories. |
<static> void
|
mv(from, to)
Moves a file to another |
<static> Object
|
printf(format, args)
A C-like printf |
<static> void
|
pwd()
Print the working directory |
<static> void
|
quit(code)
synonym for exit |
<static> Object
|
read(prompt, multiline)
Reads one or more lines from stdin after printing a prompt |
<static> void
|
ren(from, to)
A synonym for 'mv'. |
<static> Object
|
rm(pathname)
Removes a given file |
<static> void
|
rmdir(pathname)
Removes a given directory |
<static> void
|
which(cmd)
Prints which command is selected from PATH |
<static> Object
|
XMLDocument(inp)
Converts input to DOM Document object |
<static> Object
|
XMLResult(out)
Converts an arbitrary stream, file to an XMLResult |
<static> Object
|
XMLSource(inp)
Converts an arbitrary stream, file, URL to an XMLSource |
<static> void
|
XSLTransform(inp, style, out)
Perform XSLT transform |
| Method Detail |
<static> void cat(obj, pattern)
cat('test.txt'); // show test.txt file contents
cat('http://java.net'); // show the contents from the URL http://java.net
obj
- input to show
pattern
- optional. Show only the lines matching the pattern
<static> void cd(target)
target
- the directory to change to. optional, defaults to user's HOME
<static> void cp(from, to)
from
- the input file, URL, or stream
to
- the output stream or file
<static> void date()
<static> void del(pathname)
<static> void dir(d, filter)
<static> Object dirname(pathname)
pathname
- the input path name
<static> void echo(x)
<static> void exec(cmd)
cmd
- the command to execute in child process
<static> void exit(exitCode)
exitCode
- the integer code to be returned to the OS shell. Optional, defaults to 0
<static> void find(dir, pattern, callback)
find('.')
find('.', '.*\.class', rm); // remove all .class files
find('.', '.*\.java'); // print fullpath of each .java file
find('.', '.*\.java', cat); // print all .java files
dir
- the directory of files to search
pattern
- the pattern to search for
callback
- the function to call for matching files
<static> void grep(pattern, files )
pattern
- the pattern to search for
files
- one or more files to be searched
<static> void ip(name)
name
- the domain name
<static> void load(str)
load('test.js'); // load script file 'test.js'
load('http://java.sun.com/foo.js'); // load from a URL
str
- the input from which the script is loaded and evaluated
<static> void ls(dir, filter)
dir
- the directory from which to list the files. Optional, default to pwd
filter
- a pattern to filter the files listed. Optional, default is '.'
<static> void mkdir(dir)
dir
- the name of the new directory
<static> void mkdirs(dir)
dir
- the pathname of the directory to be created
<static> void mv(from, to)
from
- the original name of the file
to
- the new name for the file
<static> Object printf(format, args)
format
- the string to format the rest of the print items
args
- the variadic argument list
<static> void pwd()
<static> void quit(code)
<static> Object read(prompt, multiline)
prompt
- the prompt. Optional, default is '>'
multiline
- if 0, read a single line, else read multiple lines
<static> void ren(from, to)
<static> Object rm(pathname)
pathname
- the name of the file
<static> void rmdir(pathname)
pathname
- the name of the directory
<static> void which(cmd)
cmd
- the name of the command searched from PATH
<static> Object XMLDocument(inp)
inp
- a file or reader. Optional, If missing a new DOM Document is returned.
<static> Object XMLResult(out)
inp
- the input stream or file
<static> Object XMLSource(inp)
inp
- the input stream, file, or URL
<static> void XSLTransform(inp, style, out)
inp
- the input XML to transform (URL, File or InputStream)
style
- the XSL Stylesheet to be used (URL, File or InputStream). Optional.
out
- the output XML (File or OutputStream)
|
||||||||
| PREV CLASS NEXT CLASS | ||||||||
| SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |


Programming and application development provides a seemingly endless stream of potential knowledge that I have been soaking myself in for nearly two years.
I majored in English with a concentration in writing at Lousiana State University because I loved to create. I discovered and minored in Philosophy there because I love to logically solve problems, and I didn't worry about the amount of course work this would provide me because I am diligent, and I love to learn.
It wasn't until, five year after graduating and becoming a teacher, that I discovered programming, which perfectly combines those three passions: creating, problem solving, and learning. Once I decided to change careers, I quickly began to absorb knowledge and build skills.
At Bloc, I learned Ruby and Ruby on Rails, Data Seeding, Test-Driven Development, Authentication, Authorization, Building and Using APIs, AJAX, and JSON to build out scalable and perfomant backends, HTML, CSS, JavaScript, jQuery, AngularJS to build user interfaces that run smoothly, intuitively, and beauitifully.
At IBM, I took advantage of classes in Java and Swift for Android and iOS Development and Bluemix, design patterns, algorithms, security which allowed me to grow as a developer. I, also, began my first project building out the Angular front end for an application that used Watson technology to quickly and efficiently find caparables for companies being audited. During which time, I gained experience in UI Grid, Angular Material, Agile Development and more.
At Trinity Integrated Solutions, I worked on multiple applications at a time. Some applications were built in QuickBase, which was created to limit the need for code, and therefore, required that I focus on building JavaScript, jQuery, CSS, and HTML skills. Other applications were mobile based, built using Node.JS, Express.JS, AngularJS, Ionic, Cordova as well as Jade, Sass, Angular Material, and other tools.
Currently, I am working part-time, at night and on weekends, for Alzcare Labs a company that is working build technology that will serve as an infrastructure for dementia-friendly communities. I have built their top level website (alzcarelabs.com) and will be leading the devlopment of their React Native iOS application that connects to their FindMe wearable IoT device.
Because this is not a full time position, I am hoping to find a company whose needs fits my skill set.


IMPORTANT This feature is experimental and is not complete. IMPORTANT Enabling this feature and running Docker containers in your cluster has security implications. With this feature enabled, it may be possible to gain root access to the YARN NodeManager hosts. Given Docker’s integration with many powerful kernel features, it is imperative that administrators understand Docker security before enabling this feature.
Docker combines an easy-to-use interface to Linux containers with easy-to-construct image files for those containers. In short, Docker enables users to bundle an application together with its preferred execution environment to be executed on a target machine. For more information about Docker, see their documentation.
The Linux Container Executor (LCE) allows the YARN NodeManager to launch YARN containers to run either directly on the host machine or inside Docker containers. The application requesting the resources can specify for each container how it should be executed. The LCE also provides enhanced security and is required when deploying a secure cluster. When the LCE launches a YARN container to execute in a Docker container, the application can specify the Docker image to be used.
Docker containers provide a custom execution environment in which the application’s code runs, isolated from the execution environment of the NodeManager and other applications. These containers can include special libraries needed by the application, and they can have different versions of native tools and libraries including Perl, Python, and Java. Docker containers can even run a different flavor of Linux than what is running on the NodeManager.
Docker for YARN provides both consistency (all YARN containers will have the same software environment) and isolation (no interference with whatever is installed on the physical machine).
Docker support in the LCE is still evolving. To track progress, follow YARN-3611, the umbrella JIRA for Docker support improvements.
The LCE requires that container-executor binary be owned by root:hadoop and have 6050 permissions. In order to launch Docker containers, the Docker daemon must be running on all NodeManager hosts where Docker containers will be launched. The Docker client must also be installed on all NodeManager hosts where Docker containers will be launched and able to start Docker containers.
To prevent timeouts while starting jobs, any large Docker images to be used by an application should already be loaded in the Docker daemon’s cache on the NodeManager hosts. A simple way to load an image is by issuing a Docker pull request. For example:
sudo docker pull images/hadoop-docker:latest
The following properties should be set in yarn-site.xml:
<configuration> <property> <name>yarn.nodemanager.container-executor.class</name> <value>org.apache.hadoop.yarn.server.nodemanager.LinuxContainerExecutor</value> <description> This is the container executor setting that ensures that all applications are started with the LinuxContainerExecutor. </description> </property> <property> <name>yarn.nodemanager.linux-container-executor.group</name> <value>hadoop</value> <description> The POSIX group of the NodeManager. It should match the setting in "container-executor.cfg". This configuration is required for validating the secure access of the container-executor binary. </description> </property> <property> <name>yarn.nodemanager.linux-container-executor.nonsecure-mode.limit-users</name> <value>false</value> <description> Whether all applications should be run as the NodeManager process' owner. When false, applications are launched instead as the application owner. </description> </property> <property> <name>yarn.nodemanager.runtime.linux.allowed-runtimes</name> <value>default,docker</value> <description> Comma separated list of runtimes that are allowed when using LinuxContainerExecutor. The allowed values are default and docker. </description> </property> <property> <name>yarn.nodemanager.runtime.linux.docker.allowed-container-networks</name> <value>host,none,bridge</value> <description> Optional. A comma-separated set of networks allowed when launching containers. Valid values are determined by Docker networks available from `docker network ls` </description> </property> <property> <name>yarn.nodemanager.runtime.linux.docker.default-container-network</name> <value>host</value> <description> The network used when launching Docker containers when no network is specified in the request. This network must be one of the (configurable) set of allowed container networks. </description> </property> <property> <name>yarn.nodemanager.runtime.linux.docker.privileged-containers.allowed</name> <value>false</value> <description> Optional. Whether applications are allowed to run in privileged containers. </description> </property> <property> <name>yarn.nodemanager.runtime.linux.docker.privileged-containers.acl</name> <value></value> <description> Optional. A comma-separated list of users who are allowed to request privileged contains if privileged containers are allowed. </description> </property> <property> <name>yarn.nodemanager.runtime.linux.docker.capabilities</name> <value>CHOWN,DAC_OVERRIDE,FSETID,FOWNER,MKNOD,NET_RAW,SETGID,SETUID,SETFCAP,SETPCAP,NET_BIND_SERVICE,SYS_CHROOT,KILL,AUDIT_WRITE</value> <description> Optional. This configuration setting determines the capabilities assigned to docker containers when they are launched. While these may not be case-sensitive from a docker perspective, it is best to keep these uppercase. To run without any capabilites, set this value to "none" or "NONE" </description> </property> </configuration>
In addition, a container-executer.cfg file must exist and contain settings for the container executor. The file must be owned by root with permissions 0400. The format of the file is the standard Java properties file format, for example
`key=value`
The following properties are required to enable Docker support:
| Configuration Name | Description |
|---|---|
| yarn.nodemanager.linux-container-executor.group | The Unix group of the NodeManager. It should match the yarn.nodemanager.linux-container-executor.group in the yarn-site.xml file. |
The container-executor.cfg must contain a section to determine the capabilities that containers are allowed. It contains the following properties:
| Configuration Name | Description |
|---|---|
| module.enabled | Must be “true” or “false” to enable or disable launching Docker containers respectively. Default value is 0. |
| docker.binary | The binary used to launch Docker containers. /usr/bin/docker by default. |
| docker.allowed.capabilities | Comma separated capabilities that containers are allowed to add. By default no capabilities are allowed to be added. |
| docker.allowed.devices | Comma separated devices that containers are allowed to mount. By default no devices are allowed to be added. |
| docker.allowed.networks | Comma separated networks that containers are allowed to use. If no network is specified when launching the container, the default Docker network will be used. |
| docker.allowed.ro-mounts | Comma separated directories that containers are allowed to mount in read-only mode. By default, no directories are allowed to mounted. |
| docker.allowed.rw-mounts | Comma separated directories that containers are allowed to mount in read-write mode. By default, no directories are allowed to mounted. |
| docker.privileged-containers.enabled | Set to 1 or 0 to enable or disable launching privileged containers. Default value is 0. |
Please note that if you wish to run Docker containers that require access to the YARN local directories, you must add them to the docker.allowed.rw-mounts list.
In addition, containers are not permitted to mount any parent of the container-executor.cfg directory in read-write mode.
The following properties are optional:
| Configuration Name | Description |
|---|---|
| min.user.id | The minimum UID that is allowed to launch applications. The default is no minimum |
| banned.users | A comma-separated list of usernames who should not be allowed to launch applications. The default setting is: yarn, mapred, hdfs, and bin. |
| allowed.system.users | A comma-separated list of usernames who should be allowed to launch applications even if their UIDs are below the configured minimum. If a user appears in allowed.system.users and banned.users, the user will be considered banned. |
| feature.tc.enabled | Must be 0 or 1. 0 means traffic control commands are disabled. 1 means traffic control commands are allowed. |
Part of a container-executor.cfg which allows Docker containers to be launched is below:
yarn.nodemanager.linux-container-executor.group=yarn [docker] module.enabled=true docker.allowed.capabilities=SYS_CHROOT,MKNOD,SETFCAP,SETPCAP,FSETID,CHOWN,AUDIT_WRITE,SETGID,NET_RAW,FOWNER,SETUID,DAC_OVERRIDE,KILL,NET_BIND_SERVICE docker.allowed.networks=bridge,host,none docker.allowed.ro-mounts=/sys/fs/cgroup docker.allowed.rw-mounts=/var/hadoop/yarn/local-dir,/var/hadoop/yarn/log-dir
In order to work with YARN, there are two requirements for Docker images.
First, the Docker container will be explicitly launched with the application owner as the container user. If the application owner is not a valid user in the Docker image, the application will fail. The container user is specified by the user’s UID. If the user’s UID is different between the NodeManager host and the Docker image, the container may be launched as the wrong user or may fail to launch because the UID does not exist.
Second, the Docker image must have whatever is expected by the application in order to execute. In the case of Hadoop (MapReduce or Spark), the Docker image must contain the JRE and Hadoop libraries and have the necessary environment variables set: JAVA_HOME, HADOOP_COMMON_PATH, HADOOP_HDFS_HOME, HADOOP_MAPRED_HOME, HADOOP_YARN_HOME, and HADOOP_CONF_DIR. Note that the Java and Hadoop component versions available in the Docker image must be compatible with what’s installed on the cluster and in any other Docker images being used for other tasks of the same job. Otherwise the Hadoop components started in the Docker container may be unable to communicate with external Hadoop components.
If a Docker image has a command set, the behavior will depend on whether the YARN_CONTAINER_RUNTIME_DOCKER_RUN_OVERRIDE_DISABLE is set to true. If so, the command will be overridden when LCE launches the image with YARN’s container launch script.
If a Docker image has an entry point set, the entry point will be honored, but the default command may be overridden, as just mentioned above. Unless the entry point is something similar to sh -c or YARN_CONTAINER_RUNTIME_DOCKER_RUN_OVERRIDE_DISABLE is set to true, the net result will likely be undesirable. Because the YARN container launch script is required to correctly launch the YARN task, use of entry points is discouraged.
If an application requests a Docker image that has not already been loaded by the Docker daemon on the host where it is to execute, the Docker daemon will implicitly perform a Docker pull command. Both MapReduce and Spark assume that tasks which take more that 10 minutes to report progress have stalled, so specifying a large Docker image may cause the application to fail.
Before attempting to launch a Docker container, make sure that the LCE configuration is working for applications requesting regular YARN containers. If after enabling the LCE one or more NodeManagers fail to start, the cause is most likely that the ownership and/or permissions on the container-executer binary are incorrect. Check the logs to confirm.
In order to run an application in a Docker container, set the following environment variables in the application’s environment:
| Environment Variable Name | Description |
|---|---|
| YARN_CONTAINER_RUNTIME_TYPE | Determines whether an application will be launched in a Docker container. If the value is “docker”, the application will be launched in a Docker container. Otherwise a regular process tree container will be used. |
| YARN_CONTAINER_RUNTIME_DOCKER_IMAGE | Names which image will be used to launch the Docker container. Any image name that could be passed to the Docker client’s run command may be used. The image name may include a repo prefix. |
| YARN_CONTAINER_RUNTIME_DOCKER_RUN_OVERRIDE_DISABLE | Controls whether the Docker container’s default command is overridden. When set to true, the Docker container’s command will be “bash path_to_launch_script”. When unset or set to false, the Docker container’s default command is used. |
| YARN_CONTAINER_RUNTIME_DOCKER_CONTAINER_NETWORK | Sets the network type to be used by the Docker container. It must be a valid value as determined by the yarn.nodemanager.runtime.linux.docker.allowed-container-networks property. |
| YARN_CONTAINER_RUNTIME_DOCKER_RUN_PRIVILEGED_CONTAINER | Controls whether the Docker container is a privileged container. In order to use privileged containers, the yarn.nodemanager.runtime.linux.docker.privileged-containers.allowed property must be set to true, and the application owner must appear in the value of the yarn.nodemanager.runtime.linux.docker.privileged-containers.acl property. If this environment variable is set to true, a privileged Docker container will be used if allowed. No other value is allowed, so the environment variable should be left unset rather than setting it to false. |
| YARN_CONTAINER_RUNTIME_DOCKER_LOCAL_RESOURCE_MOUNTS | Adds additional volume mounts to the Docker container. The value of the environment variable should be a comma-separated list of mounts. All such mounts must be given as “source:dest”, where the source is an absolute path that is not a symlink and that points to a localized resource. Note that as of YARN-5298, localized directories are automatically mounted into the container as volumes. |
The first two are required. The remainder can be set as needed. While controlling the container type through environment variables is somewhat less than ideal, it allows applications with no awareness of YARN’s Docker support (such as MapReduce and Spark) to nonetheless take advantage of it through their support for configuring the application environment.
Once an application has been submitted to be launched in a Docker container, the application will behave exactly as any other YARN application. Logs will be aggregated and stored in the relevant history server. The application life cycle will be the same as for a non-Docker application.
Until YARN-5428 is complete, the Docker client command will draw its configuration from the default location, which is $HOME/.docker/config.json on the NodeManager host. The Docker configuration is where secure repository credentials are stored, so use of the LCE with secure Docker repos is discouraged until YARN-5428 is complete.
As a work-around, you may manually log the Docker daemon on every NodeManager host into the secure repo using the Docker login command:
docker login [OPTIONS] [SERVER] Register or log in to a Docker registry server, if no server is specified "https://index.docker.io/v1/" is the default. -e, --email="" Email -p, --password="" Password -u, --username="" Username
Note that this approach means that all users will have access to the secure repo.
To submit the pi job to run in Docker containers, run the following commands:
vars="YARN_CONTAINER_RUNTIME_TYPE=docker,YARN_CONTAINER_RUNTIME_DOCKER_IMAGE=hadoop-docker" hadoop jar hadoop-examples.jar pi -Dyarn.app.mapreduce.am.env=$vars \ -Dmapreduce.map.env=$vars -Dmapreduce.reduce.env=$vars 10 100
Note that the application master, map tasks, and reduce tasks are configured independently. In this example, we are using the hadoop-docker image for all three.
To run a Spark shell in Docker containers, run the following command:
spark-shell --master yarn --conf spark.executorEnv.YARN_CONTAINER_RUNTIME_TYPE=docker \ --conf spark.executorEnv.YARN_CONTAINER_RUNTIME_DOCKER_IMAGE=hadoop-docker \ --conf spark.yarn.appMasterEnv.YARN_CONTAINER_RUNTIME_DOCKER_IMAGE=hadoop-docker \ --conf spark.yarn.appMasterEnv.YARN_CONTAINER_RUNTIME_TYPE=docker
Note that the application master and executors are configured independently. In this example, we are using the hadoop-docker image for both.


Goals available for this plugin:
| Goal | Description |
|---|---|
| dellroad-stuff:exec-set-property | Sets a Maven project property based on the output of an arbitrary command. |
| dellroad-stuff:git-describe | Sets a Maven project property based on the output of git
describe . |
| dellroad-stuff:help | Display help information on dellroad-stuff-maven-plugin. Call mvn dellroad-stuff:help -Ddetail=true
-Dgoal=<goal-name> to display parameter details. |
| dellroad-stuff:svn-version | Sets a Maven project property based on the output of
svnversion . |
The following specifies the minimum requirements to run this Maven plugin:
| Maven | 2.0 |
| JDK | 8 |
| Memory | No minimum requirement. |
| Disk Space | No minimum requirement. |
You should specify the version in your project's plugin configuration:
<project> ... <build> <!-- To define the plugin version in your parent POM --> <pluginManagement> <plugins> <plugin> <groupId>org.dellroad</groupId> <artifactId>dellroad-stuff-maven-plugin</artifactId> <version>2.5.9</version> </plugin> ... </plugins> </pluginManagement> <!-- To use the plugin goals in your POM or parent POM --> <plugins> <plugin> <groupId>org.dellroad</groupId> <artifactId>dellroad-stuff-maven-plugin</artifactId> <version>2.5.9</version> </plugin> ... </plugins> </build> ... </project>
For more information, see "Guide to Configuring Plug-ins"


#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import random
import time
from googleapiclient.errors import HttpError
from googleapiclient.discovery import build
from airflow.contrib.hooks.gcp_api_base_hook import GoogleCloudBaseHook
from airflow.utils.log.logging_mixin import LoggingMixin
[docs]def _poll_with_exponential_delay(request, max_n, is_done_func, is_error_func):
log = LoggingMixin().log
for i in range(0, max_n):
try:
response = request.execute()
if is_error_func(response):
raise ValueError(
'The response contained an error: {}'.format(response)
)
elif is_done_func(response):
log.info('Operation is done: %s', response)
return response
else:
time.sleep((2**i) + (random.randint(0, 1000) / 1000))
except HttpError as e:
if e.resp.status != 429:
log.info('Something went wrong. Not retrying: %s', format(e))
raise
else:
time.sleep((2**i) + (random.randint(0, 1000) / 1000))
[docs]class MLEngineHook(GoogleCloudBaseHook):
def __init__(self, gcp_conn_id='google_cloud_default', delegate_to=None):
super(MLEngineHook, self).__init__(gcp_conn_id, delegate_to)
self._mlengine = self.get_conn()
[docs] def get_conn(self):
"""
Returns a Google MLEngine service object.
"""
authed_http = self._authorize()
return build('ml', 'v1', http=authed_http, cache_discovery=False)
[docs] def create_job(self, project_id, job, use_existing_job_fn=None):
"""
Launches a MLEngine job and wait for it to reach a terminal state.
:param project_id: The Google Cloud project id within which MLEngine
job will be launched.
:type project_id: str
:param job: MLEngine Job object that should be provided to the MLEngine
API, such as: ::
{
'jobId': 'my_job_id',
'trainingInput': {
'scaleTier': 'STANDARD_1',
...
}
}
:type job: dict
:param use_existing_job_fn: In case that a MLEngine job with the same
job_id already exist, this method (if provided) will decide whether
we should use this existing job, continue waiting for it to finish
and returning the job object. It should accepts a MLEngine job
object, and returns a boolean value indicating whether it is OK to
reuse the existing job. If 'use_existing_job_fn' is not provided,
we by default reuse the existing MLEngine job.
:type use_existing_job_fn: function
:return: The MLEngine job object if the job successfully reach a
terminal state (which might be FAILED or CANCELLED state).
:rtype: dict
"""
request = self._mlengine.projects().jobs().create(
parent='projects/{}'.format(project_id),
body=job)
job_id = job['jobId']
try:
request.execute()
except HttpError as e:
# 409 means there is an existing job with the same job ID.
if e.resp.status == 409:
if use_existing_job_fn is not None:
existing_job = self._get_job(project_id, job_id)
if not use_existing_job_fn(existing_job):
self.log.error(
'Job with job_id %s already exist, but it does '
'not match our expectation: %s',
job_id, existing_job
)
raise
self.log.info(
'Job with job_id %s already exist. Will waiting for it to finish',
job_id
)
else:
self.log.error('Failed to create MLEngine job: {}'.format(e))
raise
return self._wait_for_job_done(project_id, job_id)
[docs] def _get_job(self, project_id, job_id):
"""
Gets a MLEngine job based on the job name.
:return: MLEngine job object if succeed.
:rtype: dict
Raises:
googleapiclient.errors.HttpError: if HTTP error is returned from server
"""
job_name = 'projects/{}/jobs/{}'.format(project_id, job_id)
request = self._mlengine.projects().jobs().get(name=job_name)
while True:
try:
return request.execute()
except HttpError as e:
if e.resp.status == 429:
# polling after 30 seconds when quota failure occurs
time.sleep(30)
else:
self.log.error('Failed to get MLEngine job: {}'.format(e))
raise
[docs] def _wait_for_job_done(self, project_id, job_id, interval=30):
"""
Waits for the Job to reach a terminal state.
This method will periodically check the job state until the job reach
a terminal state.
Raises:
googleapiclient.errors.HttpError: if HTTP error is returned when getting
the job
"""
if interval <= 0:
raise ValueError("Interval must be > 0")
while True:
job = self._get_job(project_id, job_id)
if job['state'] in ['SUCCEEDED', 'FAILED', 'CANCELLED']:
return job
time.sleep(interval)
[docs] def create_version(self, project_id, model_name, version_spec):
"""
Creates the Version on Google Cloud ML Engine.
Returns the operation if the version was created successfully and
raises an error otherwise.
"""
parent_name = 'projects/{}/models/{}'.format(project_id, model_name)
create_request = self._mlengine.projects().models().versions().create(
parent=parent_name, body=version_spec)
response = create_request.execute()
get_request = self._mlengine.projects().operations().get(
name=response['name'])
return _poll_with_exponential_delay(
request=get_request,
max_n=9,
is_done_func=lambda resp: resp.get('done', False),
is_error_func=lambda resp: resp.get('error', None) is not None)
[docs] def set_default_version(self, project_id, model_name, version_name):
"""
Sets a version to be the default. Blocks until finished.
"""
full_version_name = 'projects/{}/models/{}/versions/{}'.format(
project_id, model_name, version_name)
request = self._mlengine.projects().models().versions().setDefault(
name=full_version_name, body={})
try:
response = request.execute()
self.log.info('Successfully set version: %s to default', response)
return response
except HttpError as e:
self.log.error('Something went wrong: %s', e)
raise
[docs] def list_versions(self, project_id, model_name):
"""
Lists all available versions of a model. Blocks until finished.
"""
result = []
full_parent_name = 'projects/{}/models/{}'.format(
project_id, model_name)
request = self._mlengine.projects().models().versions().list(
parent=full_parent_name, pageSize=100)
response = request.execute()
next_page_token = response.get('nextPageToken', None)
result.extend(response.get('versions', []))
while next_page_token is not None:
next_request = self._mlengine.projects().models().versions().list(
parent=full_parent_name,
pageToken=next_page_token,
pageSize=100)
response = next_request.execute()
next_page_token = response.get('nextPageToken', None)
result.extend(response.get('versions', []))
time.sleep(5)
return result
[docs] def delete_version(self, project_id, model_name, version_name):
"""
Deletes the given version of a model. Blocks until finished.
"""
full_name = 'projects/{}/models/{}/versions/{}'.format(
project_id, model_name, version_name)
delete_request = self._mlengine.projects().models().versions().delete(
name=full_name)
response = delete_request.execute()
get_request = self._mlengine.projects().operations().get(
name=response['name'])
return _poll_with_exponential_delay(
request=get_request,
max_n=9,
is_done_func=lambda resp: resp.get('done', False),
is_error_func=lambda resp: resp.get('error', None) is not None)
[docs] def create_model(self, project_id, model):
"""
Create a Model. Blocks until finished.
"""
if not model['name']:
raise ValueError("Model name must be provided and "
"could not be an empty string")
project = 'projects/{}'.format(project_id)
request = self._mlengine.projects().models().create(
parent=project, body=model)
return request.execute()
[docs] def get_model(self, project_id, model_name):
"""
Gets a Model. Blocks until finished.
"""
if not model_name:
raise ValueError("Model name must be provided and "
"it could not be an empty string")
full_model_name = 'projects/{}/models/{}'.format(
project_id, model_name)
request = self._mlengine.projects().models().get(name=full_model_name)
try:
return request.execute()
except HttpError as e:
if e.resp.status == 404:
self.log.error('Model was not found: %s', e)
return None
raise


|
To Scan Or Not To Scan
This month's responses are provided by Dr. Janet Storella, a radiologist who is medical director of GCM-Suburban Imaging in Bethesda. GCM-Suburban Imaging is a collaboration between Suburban Hospital and the well-established radiology practice of Drs. Groover, Christie and Merritt. The Imaging Center is located in the new Suburban Outpatient Medical Center at 6420 Rockledge Drive, Bethesda, Maryland. For more information call Suburban On-Call at<PHONE_NUMBER>. To schedule an appointment call<PHONE_NUMBER>.
I'm confused about the different imaging technologies. What is the difference between MRI and CT.
CT (computed axial tomography) uses X-rays to see structures inside the body. These X-rays are aimed at a particular area of your body and the ones that pass through your body are received on a detector. A computer then analyzes this data and "builds" a picture of what is inside.
MRI (magnetic resonance imaging) takes advantage of the natural magnetic properties of the tissues in your body. The machine is a strong magnet that sends radio waves through the body. The magnetic tissues in the body then send a faint radio signal back. The receiver collects all those signals and the computer builds a picture of what is inside. MRI is not used for screening, only for diagnostic use.
My friend paid out of her own pocket to have a full body scan. What is this exam? What kind of technology is used?
The exam is full body CT screening. The idea, as in any screening exam, is to find disease before it becomes otherwise apparent in someone who has no symptoms or problems. Diagnostic CT scanning to examine specific parts of the body when there is a problem has been in use for decades. But scanning almost the entire body for screening is a new concept. Other examples of screening exams that most people are familiar with include screening mammography to detect breast tumors before they are felt as lumps or the PSA blood test to detect prostate cancer.
Do you recommend full body scans for people who have no symptoms of disease. What are the pros and cons.
Full body CT screening is controversial. The potential benefit is the early detection of significant diseases, such as tumors. Most of us believe that early detection saves lives -- if we find a tumor while it is still small and has not spread, presumably you can be cured.
The risk is that of radiation exposure. X-rays can cause damage to cells in your body. Even at the low doses used for screening exams there is a theoretical risk of causing cancer and we do not have exact data to estimate that risk. Of course, that risk of radiation exposure should be put into perspective and compared with other risks we take every day and don't even think about. Would you decline to live in Denver because there is a higher background radiation exposure due to the elevation?
There are other potential downsides. An abnormality can be found that is due to a benign or inconsequential process, but leads to additional testing or even a biopsy. The exam also has its limitations - it can't detect every abnormality, and so a normal screening exam doesn't absolutely rule out the possibility of cancer or other significant disease.
With all these issues in mind, and after studying what data we have so far, the two exams that seem least controversial are cardiac calcium scoring to assess the risk of cardiovascular disease and screening CT of the lungs in smokers over the age of 50.
Do I need a doctor's referral? Do I have to pay out of pocket?
Insurance companies do not pay for these screening exams and so up front payment at the time of the exam is expected. Some centers require a doctor's referral and others do not. You would have to check with a specific center.
What is virtual colonoscopy? What are the pros and cons? Is it better than having regular colonoscopy?
Virtual colonoscopy is a CT screening exam to look inside the colon without having to pass a scope into the colon. It still requires a preparation to clean out the bowel and you still need to pump some air into the colon. However, the exam itself is more comfortable than regular colonoscopy and therefore no sedation is required. An advantage of a regular colonoscopy is the ability to perform a biopsy of an abnormal area at the same time, but this also adds an additional risk of perforation (creating a hole in the colon).
Don't these different technologies use radiation and isn't that dangerous?
See above.
What is a PET scan?
PET scanning is a new imaging test that looks at the metabolic activity of tissues. It uses a radio-labelled glucose analog that accumulates in tissues with high metabolic rates. The tissue of many cancers grows rapidly and have a high metabolic rate even if they are small. This is in contrast to CT scanning, which relies on changes in size and shape of tissues to recognize abnormalities. This new PET technology is very promising and has been approved for use in evaluating several tumors including lymphoma, melanoma, lung cancer, and colon cancer.
For More Information Contact Suburban
Hospital
The responses provided on this web site are for informational purposes
only and are not a substitute for a visit to your personal physician.
We strongly advise you to contact your personal physician.
|


"An Enthusiastic Engineer waiting for an opportunity to dive into new technologies and swim on the complex business needs"
View details »


arrow
octicon
d3-Olympics
:
An interactive and storytelling data visualisation displaying olympics results
.
Prabhat Kumar — CEO, Founder & Data Scientist.
Africa
Asia
America
Europe
Australia


Now we are on to the finals! The algorithm enters the finals with a 6-4 record so far. Here is what we have for tonight:
So, let's see if OKC wins this one.
--- layout: post title: "NBA Predictions -- Finals" date: 2012-06-12T12:05:00-07:00 categories: - basketball - okc - Miami - NBA - finals - Thunder - Oklahoma City - game 1 - nba finals - mia - Heat ---


Look at me!
Click me!
Hi ho, Silver!
Look at me!
I'm Glowing!
Hi ho, Silver!
Call to Action
Hi ho, Silver!
Look at me!
Got clicks?
Click me!
I'm Glowing!
Click me!
Hi ho, Silver!
Got clicks?
I'm Glowing!
Call to Action
Look at me!
Got clicks?
I'm Glowing!
Click me!
Got clicks?
Click me!
I'm Glowing!
Call to Action
Got clicks?


We are currently experiencing a problem with this service and are working to fix it as soon as possible.
Please try again later or contact the project team
We are currently experiencing a problem with this service and are working to fix it as soon as possible.
Please try again later or contact the project team


My weekly blog was written in an informal tone, as if it were my diary.
If you would like to look at my work my more in detail in a professional tone, please refer to the final report.
{% for post in site.posts %}
{{ post.excerpt }}
Read More
{% endfor %}


assigned
by None at 2021-07-02 19:40:30.closed
by None at 2021-07-02 20:36:29.renamed
by None at 2021-07-02 20:46:09.closed
by None at 2021-07-02 20:46:11.assigned
by None at 2021-07-02 20:39:06.closed
by None at 2021-07-02 21:09:23.assigned
by None at 2021-07-02 20:37:36.closed
by None at 2021-07-02 21:09:39.assigned
by None at 2021-07-02 20:50:15.closed
by None at 2021-07-02 21:09:39.Since we're using the bottom of the call slip for the hold workflow, this may be tricky to implement. It requires controlling the size of the line that the image will go on. I'll look into it.
assigned
by None at 2021-07-02 21:11:28.assigned
by None at 2021-07-02 21:31:18.closed
by None at 2021-07-02 21:53:28.review_requested
by None at 2021-07-02 21:21:10.review_requested
by None at 2021-07-02 21:21:10.ready_for_review
by None at 2021-07-02 21:21:31.referenced
by Peter Green at 2021-07-02 21:55:16.merged
by Peter Green at 2021-07-02 21:55:16.closed
by Peter Green at 2021-07-02 21:55:16.head_ref_deleted
by Peter Green at 2021-07-02 21:55:24.added Marie's request to this PR
review_requested
by None at 2021-07-02 21:20:26.review_requested
by None at 2021-07-02 21:20:26.referenced
by Peter Green at 2021-07-02 21:55:34.merged
by Peter Green at 2021-07-02 21:55:34.closed
by Peter Green at 2021-07-02 21:55:34.head_ref_deleted
by Peter Green at 2021-07-02 21:55:50.referenced
by Trey Pendragon at 2021-07-01 23:29:51.merged
by Trey Pendragon at 2021-07-01 23:29:51.closed
by Trey Pendragon at 2021-07-01 23:29:51.head_ref_deleted
by Trey Pendragon at 2021-07-01 23:29:51.referenced
by Trey Pendragon at 2021-07-01 23:30:10.merged
by Trey Pendragon at 2021-07-01 23:30:10.closed
by Trey Pendragon at 2021-07-01 23:30:10.head_ref_deleted
by Trey Pendragon at 2021-07-01 23:30:10.head_ref_force_pushed
by Trey Pendragon at 2021-07-01 23:28:53.referenced
by None at 2021-07-02 13:45:39.merged
by None at 2021-07-02 13:45:39.closed
by None at 2021-07-02 13:45:39.head_ref_deleted
by None at 2021-07-02 13:45:40.deployed
by Trey Pendragon at 2021-07-02 12:48:16.deployed
by Trey Pendragon at 2021-07-02 12:48:23.referenced
by Trey Pendragon at 2021-07-01 23:21:02.referenced
by Trey Pendragon at 2021-07-01 23:28:53.closed
by None at 2021-07-02 13:46:37.labeled
by None at 2021-07-02 14:48:32.assigned
by None at 2021-07-02 15:17:06.@christinach shall we close this since we're about to move to the new infrastructure?
oops I pushed the wrong button -- just meant to ask!
closed
by None at 2021-07-02 15:44:51.mentioned
by Christina Chortaria at 2021-07-02 15:44:51.subscribed
by Christina Chortaria at 2021-07-02 15:44:51.reopened
by None at 2021-07-02 15:45:11.labeled
by None at 2021-07-02 15:52:29.renamed
by None at 2021-07-02 16:00:41.We have code getting location info from Alma.
closed
by None at 2021-07-02 16:01:14.I'm removing the block label because according to the timeline exlibris would have released the update we required; anyone picking up the ticket will need to check!
unlabeled
by None at 2021-07-02 16:05:20.unlabeled
by None at 2021-07-02 16:05:20.labeled
by None at 2021-07-02 16:05:20.This is the chart I made for reviewing all the integrations: https://docs.google.com/spreadsheets/d/1NNxpLQ5gRTOf0eGXIXgy6Qk4b6UeiBV4YHa52FNH6C4/edit?usp=sharing
I'm closing this since prod infra is done and we'll do orangelight staging infra once the premium sandbox is available, ticketed as #2546
closed
by None at 2021-07-02 16:13:17.I have shifted work to a differed (rebased) branch (https://github.com/pulibrary/bibdata/compare/alma...issues-1204-jrgriffiniii-replace-fixtures-fixed), and I am waiting to ensure that the test suites are passing: https://app.circleci.com/pipelines/github/pulibrary/bibdata?branch=issues-1204-jrgriffiniii-replace-fixtures-fixed
I am sorry, I am deprecating this again in favor of https://github.com/pulibrary/bibdata/pull/1474
closed
by James R. Griffin III at 2021-07-02 16:38:28.Some pointers to a previous siege I did against catalog searches:
- The issue was https://github.com/pulibrary/pul_solr/issues/174
- The code to generate the random search urls is at https://github.com/pulibrary/pul_solr/tree/main/scripts
- Based on the comment in that issue a good command to start with might be $ siege --concurrent=25 --time=5m --file=urls.txt
Note that in this case we do want to make sure we get javascript files, and in fact we want them to execute. If it's not possible to execute the JS then I'm not sure how much value we'll get out of this exercise -- the webserver infrastructure is identical to what we currently have so we know there's not a load issue there.
assigned
by Christina Chortaria at 2021-07-02 16:52:42.assigned
by Trey Pendragon at 2021-07-02 18:27:35.unassigned
by Kevin McElwee at 2021-07-02 14:24:53.unassigned
by Kevin McElwee at 2021-07-02 14:25:02.unassigned
by Kevin McElwee at 2021-07-02 14:25:13.unassigned
by Kevin McElwee at 2021-07-02 14:25:22.unassigned
by Kevin McElwee at 2021-07-02 14:25:28.referenced
by James R. Griffin III at 2021-07-02 14:37:52.merged
by James R. Griffin III at 2021-07-02 14:37:52.closed
by James R. Griffin III at 2021-07-02 14:37:52.head_ref_deleted
by James R. Griffin III at 2021-07-02 14:37:53.closed
by Kevin McElwee at 2021-07-02 15:02:58.This might be best structured in the following manner:
group_names = [
"Lib_DigPubs_Submitters",
"Lib_DigPubs_Reviewers"
]
def perform(group_name)
group = org.dspace.eperson.Group.findByName(DSpace.context, group_name)
members = org.dspace.eperson.Group.allMembers(DSpace.context, group)
items = []
members.to_a.each do |member|
objects = org.dspace.workflow.WorkflowItem.findByEPerson(DSpace.context, member)
items << objects
end
members.to_a.each do |member|
objects = org.dspace.workflow.WorkflowItem.findByEPerson(DSpace.context, member)
delta = items.uniq - objects
workflows = objects.to_a.map { |obj| DSpace::CLI::WorkflowItem.new(obj) }
workflows.each { |workflow| workflow.add_task_pool_user(member.getEmail) }
end
end
group_names.each { |group_name| perform(group_name) }
closed
by Kevin McElwee at 2021-07-02 14:41:55.closed
by Kevin McElwee at 2021-07-02 14:42:35.PRDS is addressing this in their PPPL input forms.
closed
by Kevin McElwee at 2021-07-02 14:43:16.unpinned
by Kevin McElwee at 2021-07-02 15:01:23.closed
by Kevin McElwee at 2021-07-02 14:43:52.closed
by Kevin McElwee at 2021-07-02 14:44:57.labeled
by Kevin McElwee at 2021-07-02 14:45:57.unlabeled
by Kevin McElwee at 2021-07-02 14:46:11.For this simple a CLI, this isn't necessary
renamed
by Kevin McElwee at 2021-07-02 14:26:59.closed
by Kevin McElwee at 2021-07-02 14:40:54.labeled
by Kevin McElwee at 2021-07-02 14:48:01.closed
by Kevin McElwee at 2021-07-02 14:27:35.labeled
by Kevin McElwee at 2021-07-02 14:48:18.Given we're using the public API, these values won't change
closed
by Kevin McElwee at 2021-07-02 14:49:08.labeled
by Kevin McElwee at 2021-07-02 14:49:11.closed
by Kevin McElwee at 2021-07-02 14:53:18.In a year, no problems have arisen. I think it's safe that we're giving the unique identifier, so it's good.
closed
by Kevin McElwee at 2021-07-02 14:54:05.DOE / OSTI has flagged no problems in a year. Presumably the format provided in 2020 was correct and sufficient.
closed
by Kevin McElwee at 2021-07-02 14:55:06.head_ref_deleted
by Kevin McElwee at 2021-07-02 14:55:39.referenced
by Kevin McElwee at 2021-07-02 16:19:57.merged
by Kevin McElwee at 2021-07-02 16:19:57.closed
by Kevin McElwee at 2021-07-02 16:19:57.head_ref_deleted
by Kevin McElwee at 2021-07-02 16:20:00.referenced
by Kevin McElwee at 2021-07-02 15:31:04.closed
by Kevin McElwee at 2021-07-02 16:20:14.unpinned
by Kevin McElwee at 2021-07-02 16:33:53.closed
by Kevin McElwee at 2021-07-02 16:34:08.It's currently visible in the UI 🤷
closed
by Kevin McElwee at 2021-07-02 16:34:49.The DOE team took note of this issue (see above). Thankfully this situation is rare.
renamed
by Kevin McElwee at 2021-07-02 14:54:22.review_requested
by Kate Lynch at 2021-07-02 13:56:28.referenced
by Kate Lynch at 2021-07-02 13:57:07.merged
by Kate Lynch at 2021-07-02 13:57:07.closed
by Kate Lynch at 2021-07-02 13:57:07.head_ref_deleted
by Kate Lynch at 2021-07-02 13:57:07.assigned
by Kevin McElwee at 2021-07-02 14:07:43.closed
by Kevin McElwee at 2021-07-02 14:07:47.renamed
by James R. Griffin III at 2021-07-02 17:26:38.labeled
by James R. Griffin III at 2021-07-02 17:30:44.labeled
by James R. Griffin III at 2021-07-02 17:30:48.closed
by Kevin McElwee at 2021-07-02 12:50:37.closed
by Kevin McElwee at 2021-07-02 12:50:47.referenced
by None at 2021-07-02 13:04:31.merged
by None at 2021-07-02 13:04:31.closed
by None at 2021-07-02 13:04:32.head_ref_deleted
by Zaynab Masood at 2021-07-02 13:18:28.referenced
by None at 2021-07-02 13:49:14.merged
by None at 2021-07-02 13:49:14.closed
by None at 2021-07-02 13:49:14.head_ref_deleted
by Zaynab Masood at 2021-07-02 13:52:27.referenced
by None at 2021-07-03 01:14:02.merged
by None at 2021-07-03 01:14:02.closed
by None at 2021-07-03 01:14:02.head_ref_deleted
by None at 2021-07-03 01:14:09.Needs fixes for rubocop
closed
by Kevin McElwee at 2021-07-02 14:26:02.labeled
by None at 2021-07-02 16:13:03.labeled
by None at 2021-07-02 16:13:03.Coverage remained the same at 96.738% when pulling cd3fc9c1a987ed21b99a5f5eb736bb27b7775fc2 on requests-remove-study-browse into 68c8bc27b40fa8270a1059d074e4142ee21470dc on main.
deployed
by Trey Pendragon at 2021-07-02 12:11:37.head_ref_force_pushed
by None at 2021-07-02 13:39:44.deployed
by Trey Pendragon at 2021-07-02 13:40:52.head_ref_force_pushed
by None at 2021-07-02 14:16:25.deployed
by Trey Pendragon at 2021-07-02 14:16:34.head_ref_force_pushed
by None at 2021-07-02 15:13:58.ready_for_review
by None at 2021-07-02 15:14:36.referenced
by Kevin Reiss at 2021-07-02 17:14:57.merged
by Kevin Reiss at 2021-07-02 17:14:57.closed
by Kevin Reiss at 2021-07-02 17:14:57.head_ref_deleted
by Kevin Reiss at 2021-07-02 17:14:58.assigned
by James R. Griffin III at 2021-07-02 18:33:03.Should this be closed? I'm seeing the viewer linked to 6910125 displayed on both 6910125 (host) and 6910128 (volume).
heya @jrgriffiniii besides SSH any other service ports needed for the firewall?
labeled
by James R. Griffin III at 2021-07-02 17:51:39.assigned
by Francis Kayiwa at 2021-07-02 17:51:47.mentioned
by James R. Griffin III at 2021-07-02 18:23:51.subscribed
by James R. Griffin III at 2021-07-02 18:23:51.referenced
by None at 2021-07-01 23:28:02.merged
by None at 2021-07-01 23:28:02.closed
by None at 2021-07-01 23:28:02.head_ref_deleted
by None at 2021-07-01 23:28:03.referenced
by Trey Pendragon at 2021-07-01 23:21:02.referenced
by Trey Pendragon at 2021-07-01 23:28:53.referenced
by None at 2021-07-02 13:45:56.merged
by None at 2021-07-02 13:45:56.closed
by None at 2021-07-02 13:45:56.head_ref_deleted
by None at 2021-07-02 13:45:57.referenced
by None at 2021-07-02 15:47:33.merged
by None at 2021-07-02 15:47:33.closed
by None at 2021-07-02 15:47:33.head_ref_deleted
by None at 2021-07-02 15:47:33.The siege command I used for this work was:
$ siege --concurrent=25 --time=5m --no-parser --file=urls.txt
Turning off the parser stops it from downloading images and js files and stuff -- in this case I wanted that because I was trying to stress solr and not the webserver. The time switch tells it to just go for that long and then stop.
head_ref_force_pushed
by None at 2021-07-02 01:03:41.referenced
by None at 2021-07-02 11:07:32.merged
by None at 2021-07-02 11:07:32.closed
by None at 2021-07-02 11:07:32.head_ref_deleted
by None at 2021-07-02 11:07:35.Thanks @carolyncole
mentioned
by None at 2021-07-02 12:42:30.subscribed
by None at 2021-07-02 12:42:30.referenced
by Kevin Reiss at 2021-07-02 12:42:34.merged
by Kevin Reiss at 2021-07-02 12:42:34.closed
by Kevin Reiss at 2021-07-02 12:42:34.head_ref_deleted
by Kevin Reiss at 2021-07-02 12:45:48.Here is Marquand example still including the study browse text: https://catalog-staging.princeton.edu/requests/11787670?mfhd=11449655&source=pulsearch
head_ref_force_pushed
by None at 2021-07-02 14:15:26.referenced
by Kevin Reiss at 2021-07-02 15:10:55.merged
by Kevin Reiss at 2021-07-02 15:10:55.closed
by Kevin Reiss at 2021-07-02 15:10:55.head_ref_deleted
by Kevin Reiss at 2021-07-02 15:10:58.assigned
by None at 2021-07-02 16:19:31.head_ref_force_pushed
by Shaun Ellis at 2021-07-02 14:34:29.


Docker Remote Debugging¶
To connect to python remote interpreter inside docker, you have to make sure first, that Pycharm is aware of your docker.
Go to Settings > Build, Execution, Deployment > Docker. If you are on linux, you can use docker directly using its socket unix:///var/run/docker.sock, if you are on Windows or Mac, make sure that you have docker-machine installed, then you can simply Import credentials from Docker Machine.
Configure Remote Python Interpreter¶
This repository comes with already prepared “Run/Debug Configurations” for docker.
But as you can see, at the beginning there is something wrong with them. They have red X on django icon, and they cannot be used, without configuring remote python interpreter. To do that, you have to go to Settings > Build, Execution, Deployment first.
Next, you have to add new remote python interpreter, based on already tested deployment settings. Go to Settings > Project > Project Interpreter. Click on the cog icon, and click Add Remote.
Switch to Docker Compose and select local.yml file from directory of your project, next set Service name to django
Having that, click OK. Close Settings panel, and wait few seconds…
After few seconds, all Run/Debug Configurations should be ready to use.
Things you can do with provided configuration:
run and debug python code
run and debug tests
run and debug migrations or different django management commands
and many others..
Known issues¶
Pycharm hangs on “Connecting to Debugger”
This might be fault of your firewall. Take a look on this ticket - https://youtrack.jetbrains.com/issue/PY-18913
Modified files in .idea directory
Most of the files from .idea/ were added to .gitignore with a few exceptions, which were made, to provide “ready to go” configuration. After adding remote interpreter some of these files are altered by PyCharm:
In theory you can remove them from repository, but then, other people will lose a ability to initialize a project from provided configurations as you did. To get rid of this annoying state, you can run command:
$ git update-index --assume-unchanged ovu.iml


|
GLib Framework
1.0
|
A linked list for generic drawables. More...
#include <drawable.h>
Data Fields | |
| unsigned long | id |
| unsigned int | priority |
| unsigned int | free_strategy |
| TDrawable * | drawable |
| struct TDrawable_Node * | next |
A linked list for generic drawables.
TDrawable_Node is an linked list for stock differents types of drawables.
| TDrawable* drawable |
The drawable object.
| unsigned int free_strategy |
The free strategy to use.
| unsigned long id |
An unique ID for each drawable.
| struct TDrawable_Node* next |
A pointer to the next TDrawable_Node.
| unsigned int priority |
The drawing priority, the lower the priority (close to 1), the more it will be drawn last.


28 Sep 2016
Sept 28
Scrawlings
Open problems and recent work
- Unsolved problem in computer science:
- Does linear programming admit a strongly polynomial-time algorithm?
- (more unsolved problems in computer science)
- Does LP admit a strongly polynomial-time algorithm?
- Does LP admit a strongly polynomial algorithm to find a strictly complementary solution?
- Does LP admit a polynomial algorithm in the real number (unit cost) model of computation?
- Are there pivot rules which lead to polynomial-time Simplex variants?
- Do all polytopal graphs have polynomially bounded diameter?
Question: Why does the theory about linear programs seem to be better developed than that about nonlinear programs? Why are people generally more interested interested in linear programs than the greater optimization framework? (Or, at least, why is Wikipedia more interested in LPs than the greater framework?)
Question: Is there tension between traditional optimization and reinforcement learning?
26 Sep 2016
Sept 26 2016
Boyd
Diamond
Agrawal
Investigating alternate methods of solving LPs and SOCPs.
- Cutting plane methods
- Proximal methods
- An analog of conjugate gradients?
- AA^T to solve linear system, A = 10 rows by 10 Million Columns
- Alternating projections while retaining inequalities (affine and conic subspace)
- Alternating projections while retaining a limited number of inequalities or sketching the inequalities
- Alternating projections or some other algorithm that solves a series of QCQPs to solve an SOCP (project onto a polyhedron, or onto a convex hull of inequalities)
- The catchmark algorithm applied to SOCPs
- A randomized approach to solving or approximating LPs or QCQPs
- (random ), project onto that hyperplane to get
LBFGS
catchmark (?)
conditional gradient programs
Pontus
non-expansive operator and fixed points
2nd order methods are metric invariant
first order methods have variable metrics (must find the right metric – norm should probably make subspaces round ish)
second order cone – diag plus rank 1
question: log-barrier and self-concordance?
Theme: Resurrecting methods from the 50’s and applying them to solving SOCPs or LPs in order to (1) better understand the power of these methods and (2) better understand the hard-ness of these optimizing these types of programs.
NB: A wide body of research into SOCPs has already been conducted.
Personal interest: I am interested in problems in which trade-offs must be made. In particular, I am currently interested in the trade-off between correctness and computational feasibility, as measured in time and/or space.


- NAME
- scan - Parse string using conversion specifiers in the style of sscanf
- SYNOPSIS
- scan string format ?varName varName ...?
- INTRODUCTION
- DETAILS ON SCANNING
- d
- o
- x
- u
- i
- c
- s
- e or f or g
- [chars]
- [^chars]
- n
- DIFFERENCES FROM ANSI SSCANF
- EXAMPLES
- SEE ALSO
- KEYWORDS
scan - Parse string using conversion specifiers in the style of sscanf
scan string format ?varName varName ...?
This command parses fields from an input string in the same fashion as the
ANSI C sscanf procedure and returns a count of the number of
conversions performed, or -1 if the end of the input string is reached
before any conversions have been performed. String gives the input
to be parsed and format indicates how to parse it, using %
conversion specifiers as in sscanf. Each varName gives the
name of a variable; when a field is scanned from string the result is
converted back into a string and assigned to the corresponding variable.
If no varName variables are specified, then scan works in an
inline manner, returning the data that would otherwise be stored in the
variables as a list. In the inline case, an empty string is returned when
the end of the input string is reached before any conversions have been
performed.
Scan operates by scanning string and format together.
If the next character in format is a blank or tab then it
matches any number of white space characters in string (including
zero).
Otherwise, if it isn't a % character then it
must match the next character of string.
When a % is encountered in format, it indicates
the start of a conversion specifier.
A conversion specifier contains up to four fields after the %:
a *, which indicates that the converted value is to be discarded
instead of assigned to a variable; a XPG3 position specifier; a number
indicating a maximum field width; a field size modifier; and a
conversion character.
All of these fields are optional except for the conversion character.
The fields that are present must appear in the order given above.
When scan finds a conversion specifier in format, it
first skips any white-space characters in string (unless the
specifier is [ or c).
Then it converts the next input characters according to the
conversion specifier and stores the result in the variable given
by the next argument to scan.
If the % is followed by a decimal number and a $, as in
``%2$d'', then the variable to use is not taken from the next
sequential argument. Instead, it is taken from the argument indicated
by the number, where 1 corresponds to the first varName. If
there are any positional specifiers in format then all of the
specifiers must be positional. Every varName on the argument
list must correspond to exactly one conversion specifier or an error
is generated, or in the inline case, any position can be specified
at most once and the empty positions will be filled in with empty strings.
The following conversion characters are supported:
- d
-
The input field must be a decimal integer.
It is read in and the value is stored in the variable as a decimal string.
If the l or L field size modifier is given, the scanned
value will have an internal representation that is at least 64-bits in
size.
- o
-
The input field must be an octal integer. It is read in and the
value is stored in the variable as a decimal string.
If the l or L field size modifier is given, the scanned
value will have an internal representation that is at least 64-bits in
size.
If the value exceeds MAX_INT<PHONE_NUMBER>77 on platforms using 32-bit
integers when the l and L modifiers are not given), it
will be truncated to a signed integer. Hence,<PHONE_NUMBER>77 will
appear as -1 on a 32-bit machine by default.
- x
-
The input field must be a hexadecimal integer. It is read in
and the value is stored in the variable as a decimal string.
If the l or L field size modifier is given, the scanned
value will have an internal representation that is at least 64-bits in
size.
If the value exceeds MAX_INT (0x7FFFFFFF on platforms using 32-bit
integers when the l and L modifiers are not given), it
will be truncated to a signed integer. Hence, 0xFFFFFFFF will appear
as -1 on a 32-bit machine.
- u
-
The input field must be a decimal integer. The value is stored in the
variable as an unsigned decimal integer string.
If the l or L field size modifier is given, the scanned
value will have an internal representation that is at least 64-bits in
size.
- i
-
The input field must be an integer. The base (i.e. decimal, octal, or
hexadecimal) is determined in the same fashion as described in
expr. The value is stored in the variable as a decimal string.
If the l or L field size modifier is given, the scanned
value will have an internal representation that is at least 64-bits in
size.
- c
-
A single character is read in and its binary value is stored in
the variable as a decimal string.
Initial white space is not skipped in this case, so the input
field may be a white-space character.
This conversion is different from the ANSI standard in that the
input field always consists of a single character and no field
width may be specified.
- s
-
The input field consists of all the characters up to the next
white-space character; the characters are copied to the variable.
- e or f or g
-
The input field must be a floating-point number consisting
of an optional sign, a string of decimal digits possibly
containing a decimal point, and an optional exponent consisting
of an e or E followed by an optional sign and a string of
decimal digits.
It is read in and stored in the variable as a floating-point string.
- [chars]
-
The input field consists of any number of characters in
chars.
The matching string is stored in the variable.
If the first character between the brackets is a ] then
it is treated as part of chars rather than the closing
bracket for the set.
If chars
contains a sequence of the form a-b then any
character between a and b (inclusive) will match.
If the first or last character between the brackets is a -, then
it is treated as part of chars rather than indicating a range.
- [^chars]
-
The input field consists of any number of characters not in
chars.
The matching string is stored in the variable.
If the character immediately following the ^ is a ] then it is
treated as part of the set rather than the closing bracket for
the set.
If chars
contains a sequence of the form a-b then any
character between a and b (inclusive) will be excluded
from the set.
If the first or last character between the brackets is a -, then
it is treated as part of chars rather than indicating a range.
- n
-
No input is consumed from the input string. Instead, the total number
of characters scanned from the input string so far is stored in the variable.
The number of characters read from the input for a conversion is the
largest number that makes sense for that particular conversion (e.g.
as many decimal digits as possible for %d, as
many octal digits as possible for %o, and so on).
The input field for a given conversion terminates either when a
white-space character is encountered or when the maximum field
width has been reached, whichever comes first.
If a * is present in the conversion specifier
then no variable is assigned and the next scan argument is not consumed.
The behavior of the scan command is the same as the behavior of
the ANSI C sscanf procedure except for the following differences:
- [1]
-
%p conversion specifier is not currently supported.
- [2]
-
For %c conversions a single character value is
converted to a decimal string, which is then assigned to the
corresponding varName;
no field width may be specified for this conversion.
- [3]
-
The h modifier is always ignored and the l and L
modifiers are ignored when converting real values (i.e. type
double is used for the internal representation).
- [4]
-
If the end of the input string is reached before any conversions have been
performed and no variables are given, an empty string is returned.
Parse a simple color specification of the form #RRGGBB using
hexadecimal conversions with field sizes:
set string "#08D03F"
scan $string "#%2x%2x%2x" r g b
Parse a HH:MM time string, noting that this avoids problems with
octal numbers by forcing interpretation as decimals (if we did not
care, we would use the %i conversion instead):
set string "08:08" ;# *Not* octal!
if {[scan $string "%d:%d" hours minutes] != 2} {
error "not a valid time string"
}
# We have to understand numeric ranges ourselves...
if {$minutes < 0 || $minutes > 59} {
error "invalid number of minutes"
}
Break a string up into sequences of non-whitespace characters (note
the use of the %n conversion so that we get skipping over
leading whitespace correct):
set string " a string {with braced words} + leading space "
set words {}
while {[scan $string %s%n word length] == 2} {
lappend words $word
set string [string range $string $length end]
}
Parse a simple coordinate string, checking that it is complete by
looking for the terminating character explicitly:
set string "(5.2,-4e-2)"
# Note that the spaces before the literal parts of
# the scan pattern are significant, and that ")" is
# the Unicode character \u0029
if {
[scan $string " (%f ,%f %c" x y last] != 3
|| $last != 0x0029
} then {
error "invalid coordinate string"
}
puts "X=$x, Y=$y"
format, sscanf
conversion specifier, parse, scan
Copyright © 1993 The Regents of the University of California.
Copyright © 1994-1996 Sun Microsystems, Inc.
Copyright © 2000 Scriptics Corporation.
Copyright © 1995-1997 Roger E. Critchlow Jr.


Hello! My name is Caroline. I am learning Coding and it is about to change my world. I am learning this new skill which will advance me in the computer world and increase my technical skill to another level. I am learning how to develop websites and to use my coding skills to get a better job.
"Declare variables and live long"


Loops in Ruby
Loops are great. They're the reason computers can do all sorts of complex and computing equations that would take normal humans a very long time to come up with. And because computers are so good at performing equations, it makes sense to use them to search, to sort data, to add stuff to other stuff, and what have you. Generally in computer science there are 2 main kinds of looping conventions - a 'for' loop and a 'while' loop. In this blog, I'll cover these, and go into a brief discussion on some of Ruby's simplified methods which make looping more accessable for many people.
The 'while' loop
The while loop works as it sounds. While a condition is met (true), the following formula keeps going and making its appropriate calulations. This is useful in instances where we don't have a definite limit on how many loops we want to go through. For example
while x < y {x++}
This loop is relatively simple- it means that the loop will not stop until x is matching or a higher value than y. AND we can keep iterating however many times neccessary until the condition is met. The problem many people face with this however, is that it is easy to get yourself into an infinite loop- which your computer will no appreciate that much! To avoid this, look carefully at your conditional statement, and make sure that the condition will eventually be met!
The 'until' Loop
This is another way to phrase a 'while' loop- just the reverse. It will continue looping until the stated condition is true- whereas with a while loop it is waiting for the condition to prove false. There are very few instances where you really need this as opposed to a 'while', but if it helps you understand, power to you.
until x > y {x++}
The 'for' loop
This is the other major looping method aside from 'while'. This loops through a specified range and iterates ONLY within this range. This means you avoid the trappings of accidently falling into an infinite loop (you can still do it though). This is particularly useful when you apply it to data sets, such as arrays, hashes or strings.
for i in [1,2,3] {print i} #=>123
As demonstrated above, this will go througfh each item in an object(in this case an array) starting at the first instance '[0]'. This is easy enough to use, but can get quite clunky when dealing with datasets with an unknown quantity of data. Also, rubyists don't really use it much because there are more eloquent ways (thanks to some syntactic sugar) to do essentially the same thing.
The .each Method
So, this is the most common way to flip through each item in a dataset. As suggested in the name, it goes through 'each item'. The nice thing about this is that you can put a loop eloquently into a single line.
[1,2,3].each {|x| puts x} #=>123
As shown above, this loop runs through each element in the array and performs the subsequent operation. 'x' represents the content of the each iteration, as opposed to the index. This is pretty nice in this situation, but in others it may no quite suit your needs- you may prefer to have an index to refer to rather than what is contained inside the array. For that though, it might be useful to use the next type of loop
The .times Method
This is another 'for' spinoff that covers a specified range, but this time you specify EXACTLY how many loops you want to do.
[1,2,3].length.times {|x| print x} #=>012
See? It's a little bit different than the each method. Here, 'x' referred to the index - ie the placeholder of each item in the array that the loop went through. Also, we know that the loop only went through 3 times, since the [1,2,3].length is 3. That's it - no infinite loops here!
I hope this has been useful to you, and that it is true!


David's MTB Spring Rate Calc
Inputs
How to figure out your bike's leverage ratio curve
- Get it directly from the manufacturer (see MY20 Transition Scout or Nicolai G1)
- Pinkbike's "behind the numbers" series (see MY20 Santa Cruz Megatower)
- Antonio Osuna's LinkageDesign page (see MY20 Specialized Enduro)
- Model your frame using LinkageX3
- Measure it directly on your frame (requires tools/knowledge... guide coming soon)
How it works
The script of the constant leverage ratio calculator works as follows.
- Compute rear axle sprung weight in pounds from rider/bike weight and geometry.
Assumes % Rear = (1- chainstay/wheelbase) - Compute shock gas force and preload
- Compute how much shock stroke in inches is used with the computed rear weight value.
(spring rate)*(sag) + gas force + preload = (rear sprung weight)*(avg LR)... solve for sag - Compute summary statistics from that sag value (sag in %, wheel rate, bottom out, natural freq, etc..)
The script of the linear leverage ratio calculator works the same, except the "avg LR" in the equation is swapped for LR at that specific stroke value.
Because the LR changes as a function of shock stroke, an iterative solver is used to solve the equation. As of now a linear leverage ratio slope (defined by % change and average ratio) is assumed to make input easier. In the future, there will be an input table for leverage rate curve if you know that info.
MTB Suspension Setup Notes
Computing Rear Axle Weight
The best way to measure this is with a set of scales (as is done for cars)
Some simple assumptions can be made with rules of thumb, (60% XC, 65% Enduro, 70% DH), or from bike geometry/rider position ( 1 - Chainstay/Wheelbase = % Front assuming weight centered over BB)
"Progressivity"
Progressivity is a common term that appears in "MTB media". I typically see it referenced as the percent change of the leverage ratio curve from top out to bottom out. This works as a great metric for the rising rate nature of a suspenion linkage if there is a roughly linear leverage ratio curve. With nonlinearities, 2 linkages with idential % progressivity can have different force/displacement curves with the same spring.
To calculate, find the leverage ratio at top out and bottom out.
Then compute % Progressivity = (Starting LR - Ending LR)/ Starting LR.
Gas Force
All traditional IFP or bladder style dampers use a gas charge to take up shaft volume. The gas acts as an air spring. This calculator assumes a typical size IFP chamber and shaft diameter if you don't input anything. It also assumes constant gas force over stroke, because modeling IFP volume is difficult without the CAD models of the shock or detailed measurements. As I rebuild shocks and mreasure them I'll add that data in. Please message me if you can measure your shock for me.
Some Examples
| Shock | Shaft Diameter | IFP Pressure |
|---|---|---|
| Fox DHX2 (2017-2020) | .354" (9mm) | 150psi |
| Fox DHX2 (2021) | .375" | 100psi |
| EXT Storia and Arma V3 | .551" (14mm) | 55psi |
| RS Super Deluxe Coil | .5" | 250psi |
| DVO Jade | .551" (14mm) | 180psi |
| Marz Bomber/Fox VAN | .5" | 300psi |
| Cane Creek DB | .315" (8mm) | 90psi |
| Ohlins TTX22 | ??? | 180psi |
Preload and preload thread pitch
Preload
Preload is better thought of as a "BB height adjuster" or "Ride height adjuster". Adding preload doesn't make the spring stiffer, or increase your bottom out force/energy significantly. Any preload is added to your shock's gas force to get the total force needed to start suspension movement (anything greater than zero is bad!). High preload == harshness!
Thread Pitch
How many threads per inch the preload adjuster is threaded with. Shocks made by US companies will probably have inch standard threads, measured in TPI (Threads per inch). You can measure this with a thread guage (included in many tap-and-die sets). Metric threads are standardized by the pitch (i.e. M20x1mm) where the 1mm is the pitch. To convert this number to TPI, use the formula:
TPI = 1/(25.4 * Metric Pitch (mm) )
| Shock | Thread Pitch |
|---|---|
| Fox | 24 TPI |


Hot Restaurant
Book your seat before they are all gone!
Make Reservation
Current Reservations
<<<<<<< HEAD:app/public/tables.html
Demo Example
Demo Example
Demo Example
Demo Example
Demo Example
Demo Example
=======
>>>>>>> 820855ae107fa0ddb1d935062adf02a2b21387f5:tables.html
Waiting List


| Algorithm: | YescryptR32 |
| Block time: | 2.0 minutes |
| Block reward: | flexible (Max 50 MANO) |
| Total MANO: | 60 million MANO |
| Difficulty re-target: | every block (Half-DGWv3) |
| Premine: | none |
| Masternode: | yes (1000 MANO to run) |
| Privatesend: | yes |
| Instantsend: | yes |
| P2P Port: | 9983 |
| RPC Port: | 9984 |


B-Hive Living
Williams Jhonson Mota / UK, Portugal
Williams Jhonson Mota /
UK, Portugal
Williams took time off and went on a journey in a search of his next mission. when he came back to London, he founded B-hive living.
The B-hive living project started in the city of London, these days they are expanding to Portugal.
When you are so focused on your tenants needs, it must be a success story. Join us to learn how it all started, what he learned in the focus groups he hosted and how they use technology to make living smarter.
B-Hive Living


|
||||||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |
Templates
interface,
and defines a set of classes that represent an XSLT stylesheet.
See:
Description
| Interface Summary | |
|---|---|
| XSLTVisitable | A class that implements this interface will call a XSLTVisitor for itself and members within it's heararchy. |
| Class Summary | |
|---|---|
| AbsPathChecker | This class runs over a path expression that is assumed to be absolute, and checks for variables and the like that may make it context dependent. |
| AVT | Class to hold an Attribute Value Template. |
| AVTPart | Class to hold a part, either a string or XPath, of an Attribute Value Template. |
| AVTPartSimple | Simple string part of a complex AVT. |
| AVTPartXPath | Simple string part of a complex AVT. |
| Constants | Primary constants used in the TransformerImpl classes. |
| DecimalFormatProperties | Implement xsl:decimal-format. |
| ElemApplyImport | Implement xsl:apply-imports. |
| ElemApplyTemplates | Implement xsl:apply-templates. |
| ElemAttribute | Implement xsl:attribute. |
| ElemAttributeSet | Implement xsl:attribute-set. |
| ElemCallTemplate | Implement xsl:call-template. |
| ElemChoose | Implement xsl:choose. |
| ElemComment | Implement xsl:comment. |
| ElemCopy | Implement xsl:copy. |
| ElemCopyOf | Implement xsl:copy-of. |
| ElemElement | Implement xsl:element |
| ElemEmpty | Simple empty elem to push on the stack when nothing else got pushed, so that pop() works correctly. |
| ElemExsltFuncResult | Handles the EXSLT result element within an EXSLT function element. |
| ElemExsltFunction | Implement func:function. |
| ElemExtensionCall | Implement an extension element. |
| ElemExtensionDecl | Implement the declaration of an extension element |
| ElemExtensionScript | Implement Script extension element |
| ElemFallback | Implement xsl:fallback. |
| ElemForEach | Implement xsl:for-each. |
| ElemIf | Implement xsl:if. |
| ElemLiteralResult | Implement a Literal Result Element. |
| ElemMessage | Implement xsl:message. |
| ElemNumber | Implement xsl:number. |
| ElemOtherwise | Implement xsl:otherwise. |
| ElemParam | Implement xsl:param. |
| ElemPI | Implement xsl:processing-instruction. |
| ElemSort | Implement xsl:sort. |
| ElemTemplate | Implement xsl:template. |
| ElemTemplateElement | An instance of this class represents an element inside an xsl:template class. |
| ElemText | Implement xsl:template. |
| ElemTextLiteral | Implement a text literal. |
| ElemUnknown | Implement an unknown element |
| ElemUse | Implement xsl:use. |
| ElemValueOf | Implement xsl:value-of. |
| ElemVariable | Implement xsl:variable. |
| ElemVariablePsuedo | |
| ElemWhen | Implement xsl:when. |
| ElemWithParam | Implement xsl:with-param. |
| FuncDocument | Execute the Doc() function. |
| FuncFormatNumb | Execute the FormatNumber() function. |
| FuncKey | Execute the Key() function. |
| KeyDeclaration | Holds the attribute declarations for the xsl:keys element. |
| NamespaceAlias | Object to hold an xsl:namespace element. |
| OutputProperties | This class provides information from xsl:output elements. |
| RedundentExprEliminator | This class eleminates redundent XPaths from a given subtree, and also collects all absolute paths within the subtree. |
| Stylesheet | Represents a stylesheet element. |
| StylesheetComposed | Represents a stylesheet that has methods that resolve includes and imports. |
| StylesheetRoot | This class represents the root object of the stylesheet tree. |
| TemplateList | Encapsulates a template list, and helps locate individual templates. |
| TemplateSubPatternAssociation | A class to contain a match pattern and it's corresponding template. |
| VarNameCollector | This class visits variable refs in an XPath and collects their QNames. |
| WhiteSpaceInfo | This is used as a special "fake" template that can be handled by the TemplateList to do pattern matching on nodes. |
| XMLNSDecl | Represents an xmlns declaration |
| XSLTVisitor | A derivation from this class can be passed to a class that implements the XSLTVisitable interface, to have the appropriate method called for each component of an XSLT stylesheet. |
| XUnresolvedVariable | An instance of this class holds unto a variable until it is executed. |
| XUnresolvedVariableSimple | This is the same as XUnresolvedVariable, but it assumes that the context is already set up. |
Implements the Templates
interface,
and defines a set of classes that represent an XSLT stylesheet.
StylesheetRoot
implements the Templates
interface, and
extends StylesheetComposed
,
which is a Stylesheet
composed of itself
and its included Stylesheet objects. A StylesheetRoot also contains a
global list of all imported StylesheetComposed objects. The
role of these objects is to hold immutable stylesheet data, not to perform
procedural tasks associated with the
construction of the data (the org.apache.xalan.processor package) or with the transformation (the org.apache.xalan.transformer
package).
ElemTemplateElement
is the superclass of
all XSLT instruction elements, including Stylesheet. The xFunc classes
extend members of the org.apache.xpath package and implement XSLT functions. Unlike
the Stylesheet "container" objects, the
instruction element and function classes do contain procedural execute()
methods that are called during the transformation.
|
||||||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |