Thursday, May 19, 2016

How To Manually Install Python Modules Without pip and On A Windows Server Not Connected To The Internet

 

1) Download the modules to your laptop.

2) Copy the .tar.gz files to any temporary directory you created on the Windows server you are installing on.

3) Unzip. You will need to unzip twice as these files are Tar-ed and Zipped. You know you done it correctly when you see the folder structure and a file called setup.py.

4) Start a windows command window and CD down to the directory with setup.py.

5) Type: python setup.py install (do that for each module in their respective directory)

6) The install script will print out the status and indicate if the install was successful.

Thursday, February 11, 2016

Curious Sequence

 

On a college visit with my high school son to Rose Hullman in Terre Haute, IN  I picked up a copy of the schools’s alumni magazine.  The magazine had a section of brain teasers and logic problems written by Herb Bailey. One of the brain teasers was interesting to me since it was a challenge to write an algorithm to identify a specific number sequence called a “curious” sequence.    The brain teaser was as follows:

image

To solve this brain teaser I had to fully understand the rules of the sequence.   After analyzing the sequence, I had an idea that a curious sequence can be defined by two characteristics.  First the sequence equals n+1 when summed up.   So for n =3 for example, 2+0+2+0 = 4.   The second part is that each position reveals the number of digest in the sequence when referencing as an array with an index.    This is demonstrated below.

image

Notice how if the sequence is treated as an array and how each element of the array can be referenced by an index number.    So for the first element of the array when the index=0, the value is 2.   2 also represent the number of zeros present in the array.   Moving to the next element where the index=1 shows a value of 0.  Interesting enough there are zero 1s in the sequence of 2020.   Pretty clever to say the least! 

Now that I got a clearer understanding of the problem the question becomes, can algorithm can be created that can identify all curious sequences when n=4, but also when n=5, n=6, n=6….?    As it turns out it is very possible to develop an algorithm that will identify curious sequences in a linear time complexity.  I used Perl to impliment a solution. The results for n=3 to n=9 are shown below.

image

Wednesday, May 1, 2013

Adding a custom icon to Oracle Endeca Information Discovery

Adding an icon for a user community in Oracle Information Discovery can done exclusively using functionality under Control Panel.  However, in many cases the icon you want to add is larger than the size provided in the default Endeca theme.   The steps below show how to modify the Endeca theme to accommodate a larger icon. 

1. Change the icon under Control Panel -> Communities -> Manage Pages (of your selected community) -> Settings then click on the Logo tab. Select your file, check Use Logo and then Save.

2. Go to your Community and look at your banner. Your image may be cutoff if it was larger than the defaul “Oracle” image. You made need to adjust the size of the Endeca theme to accommodate a larger image.  Notice below how the Oracle image invades the text and black bar.

image

3. You can adjust the banner size by going to C:\Oracle\Endeca\Discovery\2.3.0\endeca-portal\tomcat-6.0.29\webapps\endeca-theme and create a directory called _diffs. Go inside that directory and create a subfolder called css Now go back into the original css directory and copy the custom.css file into the css directory you just created in the _diffs folder. This is a Liferay best practice that supports upgrades.  You should have a directory structure as follows:

clip_image001

4. Edit custom.css in _diffs/css. I made changes to height and set it to 80px and also left and set it to 300px to move the “Endeca Information Discovery” text over.   clip_image002

5. Restart your Studio service to pick up your changes.  You may need a few iterations of making changes and testing to get the sizes exactly what you want.  Remember to restart the Studio service have each change. 

image

Wednesday, January 23, 2013

Oracle Endeca Information Discovery – Changing a data source on a metrics bar component

 

I  was working with Oracle Endeca Information Discovery 2.3 and needed to change the data source on a few metric bar components.  The first thing I did was create an export of the community in a .lar file.  This was done under Control Panel –> Communities –> Actions –> Manage Pages –> Export/Import –> Export.

I tried changing the data souce under the Control Panel under Data Source Bindings.  I have used this method for other components so I figured the metrics bar component would be similar. 

image

When I went back to my metrics bar I saw I had a problem.  I got the dreaded “This component requires additional configuration”. warning.  

image 

Inspecting the metrics bar component shows that the EQL is missing.

image

I restored my Endeca community using the import function and tried a different approach.  This time I went directly into the component and selected the drop down box and selected the new data source.  I hit Update data source button. I was disappointed to see the EQL disappeared.  I had an empty metrics bar component and the dreaded “This component required additional configuration”. 

I restored my Endeca community using the import function and tried a third approach.  This time I copied the EQL and saved it to a text file.  I also copied the Display Name of each of the metric bars and noted down the Format.

I updated the data source and the EQL disappeared.  This time I was prepared.   I re-entered my EQL and hit the Test EQL button.  Once that came back I hit the Load Metrics button.  Then I entered the Display Name and Format for each metric bar.  Success.  The data source was changed. The EQL and metrics bars were present for duty.  I did not miss seeing the “This component requires additional configuration”. warning.  

image

Wednesday, December 5, 2012

Oracle Endeca Information Discovery – Partition Transformation

 

I have been working with Oracle Endeca Information Discovery tool to join structured and unstructured data together in interesting business solutions. I wanted to share my experience with the Partition Transformation and help show how it can be used to conditionally split a pipeline in an Intergrator (CloverETL) graph.

clip_image001

The transformation has properties called Ranges and Partition key. Setting the Partition key is easy. Just pick the fields from a list. Setting the Ranges is not so easy to understand.

clip_image003

See the table below that shows an example of setting the Ranges property. Setting ranges requires using an awkward syntax that uses < and > to include and ( and ) to exclude. A comma defines the low end and high end of the range. A semi-colon defines separate ranges. Sounds confusing? It is. Fortunately, there is a much easier way using CTL2.

clip_image005

For the easy way, click on the Partition attribute that drops you into the CTL2 editor. You can refer to your input fields with a $ prefix. $DOC_TYPE was defined on the import port and is an input field. Then write a conditional statement. In my example below, all rows with a $DOC_TYPE = “Operation Instructions” will be sent to port 0. All others will be sent to port 1.

clip_image007

Saturday, August 11, 2012

Authentic Communication

I believe that clients truly appreciate when consultants are genuine, authentic, and avoid technical jargon or industry clichés. To that end I am going to strive to be a more genuine and authentic in my communication style on future projects.

I will avoid pinging or reaching out to but expect me to follow up with an IM, call, email, have a face to face discussion, or schedule a meeting.

I will avoid talking to others about my bandwidth capacity or what's on my plate, but expect me to tell you the first available time I CAN help.

I will not hit the ground running, but expect me to come prepared as I can and try to be productive as soon as possible.

I will not think outside the box, but expect me to use experience and common practices as well as looking for opportunities to be creative, innovative, and consider new methods and technologies when designing solutions.

I will not architect a solution nor use the word architect as a verb but you can expect me to design and implement solutions to solve business problems.

I will not carve out time, but expect me to look for the next available time in my calendar.

I will not leverage things, when I can simply use things.

I will avoid talking about drinking kool-aid, but will question when there seems to be a blind, uncritical acceptance of a business practice or technology.

I will not refer to other human beings as a resource. You can expect me to recognize the dignity of each person and treat all my business partners, colleagues, and clients as I would want anybody in my organization to treat our very best customer.

Wednesday, July 18, 2012

What Do You Prefer - Inmon or Kimball?

I was asked that question during an interview for a position on a client project using Microsoft BI tools.  The client interviewer asked “Which do you prefer -Inmon or Kimball?”  

The question was easy for me to answer.  I could talk about how the Kimball data modeling technique called for using fact and dimension tables, star schema, conformed dimension to link different fact tables, relied on data marts, and was considered a bottom up approach. On the other hand, the Inmon data modeling technique called for a more top down approach using enterprise wide data warehouse using normalized tables. 

The client interviewer pressed on.  “Which would you choose?”   

I thought to myself.  I never really considered one over the other.  They both seemed like acceptable approaches to accomplish the same thing. 

I was first exposed to dimensional modeling and the Kimball technique in graduate school and have used it on a number of projects since then.  Building OLTP cubes in IBM Cognos Transformer and Microsoft SQL Server Analysis Services both seemed to favor using the Kimball technique.  On a few projects I used the Inmon technique.  These were typically projects I inherited or were large, very complex data models.            

I started off saying “It will depend on the project, the client......” and was abruptly cut off.  

“Which one do you prefer?” asked the client interviewer in a challenging tone.

I had to pick one. I said something like “I used both techniques in the past, but would favor the Kimball method”.

The client interviewer responded “Good!” and moved on to the next questions. 

Today in 2012 vendors have more products that use column oriented database technology that are within the price point of most companies.  Microsoft has implemented the column store index in SQL Server 2012 and uses column store technology as the engine behind Power Pivot for Excel and SharePoint 2010, and SQL Server Analysis Services in tabular mode.  Oracle has Endeca which supports ultra quick searches of structured and unstructured data.  Endeca uses a column oriented technology for its MDEX Engine.   

With column store technology so available in today’s products and CPU speed and memory size for servers continues to grow at mind numbing rates, it seems we are approaching the point that CPU and memory is not a primary constraint for many projects that have a dataset size of less than 1 terabyte. 

I began to think that I may not have the same response to the client interviewer if I was asked today .  The Inmon technique seems to have merit when considering products that use column store technology.    The Kimball star schema may not be entirely necessary with column store technology.

We also may be looking at a new approach entirely.   Perhaps a simplified variation of the Inmon technique will evolve over time.  I can see merit in modeling a few related entities that contain denormalized (repeated attributes) tables.  In data sets under 1 terabyte this approach may be something to consider as it may be faster to develop and deliver a BI solution initially. It may also help a company be more agility by supporting quicker changes and enhancement requests.