Questions tagged [palantir-foundry]

Palantir Foundry is a web-based data analytics and decision modeling SaaS platform. Use this tag for questions about building your own models in Foundry using Python, R, or SQL or working with the Foundry API.

Palantir Foundry is a web-based data analytics and decision modeling SaaS platform. Use this tag for questions about building your own models in Foundry using Python, R, or SQL or working with the Foundry API.

731 questions
2
votes
1 answer

How to fix a query in functions within foundry which is hiting ObjectSet:PagingAboveConfiguredLimitNotAllowed?

I have phonorgraph object with billions of rows and we are querying it through object set service for example, I want to get all DriverLicences from certain city. @Function() public getDriverLicences(city: string):…
2
votes
1 answer

PALANTIR-FOUNDRY: How can I add a description for a dataframe in a transform?

I am producing a dataframe through a transform. In that transform I am able to add Column description the usual way: out_all.write_dataframe(df, column_descriptions=mycols_dictionary) My question is, can I add a dataframe description in a…
2
votes
1 answer

PySpark Serialized Results too Large OOM for loop in Spark

I have serious difficulties in understanding why I cannot run a transform which, after waiting so many minutes (sometimes hours), returns the error "Serialized Results too large". In the transform I have a list of dates that I am iterating in a for…
2
votes
1 answer

How do I access a file that I uploaded to a folder from a Transform?

I uploaded an image file into a folder in Foundry, and I want to use it as an input to a Transform. It looks like it's stored as some kind of resource in a service called Blobster, how can I access this file and use it?
2
votes
2 answers

Foundry-workshop : add average value on a chart displaying parameter evolution

I'm looking for a way to display a line showing the average value of a parameter in a chart dedicated to this parameter's evolution. I have a dataset, let's take as an example the following structure : Product | Month | Price P1 2021-01 …
Christophe
  • 651
  • 4
  • 22
2
votes
1 answer

is it possible to generate pdf from datasets and save to foundry incrementally

FPDF is a library that allows to convert a pandas dataframe to nicely formatted pdf reports. Is there a feature in foundry code repo or code workbook to write pdf files into foundry from a spark or pandas dataframe ? i have a requirement to create a…
2
votes
1 answer

Copying files from a Foundry dataset to another Foundry dataset

I have two Foundry datasets that contain raw files (lets say xml or csv files). I would like to merge these two within a transform to create a new dataset with a collection from both. (This explicit example was due to a API schema being updated, and…
Patrick OC
  • 41
  • 2
2
votes
1 answer

Set Workshop Filters' default value

When we define a filter in Workshop, the output object set is used to apply users' filter options to another widget. But it's also mentioned in the documentation that setting this variable is a mean to provide et default value: how does it actually…
Christophe
  • 651
  • 4
  • 22
2
votes
1 answer

Palantir Foundry Function - cumulative revenue analysis

I would like to write a function that the following: raw data: customer product revenue Customer A Product 1 EUR 10 Customer A Product 2 EUR 10 Customer B Product 1 EUR 5 Customer B Product 2 EUR 2 Customer C Product 1 EUR…
MCHE
  • 23
  • 3
2
votes
1 answer

Why is my Code Repo warning me about using withColumn in a for/while loop?

I'm noticing my code repo is warning me that using withColumn in a for/while loop is an antipattern. Why is this not recommended? Isn't this a normal use of the PySpark API?
2
votes
4 answers

Full example of magritte REST config?

We're setting up a rest integration via magritte-rest-v2. The documentation covers auth and making rest calls, but there is nowhere will a full example config and I can't seem to get it to work. Anyone have a working config they can share for…
Tevon Strand-Brown
  • 1,283
  • 3
  • 16
  • 28
2
votes
1 answer

How to read from and write to the same file in Palantir Foundry?

I have a very simple task of updating contents of a control file in Palantir Foundry. I need to read the contents of the file, perform a check and then write back to the same file. However, if I provide the same file as Input and Output in the…
Digi
  • 75
  • 4
2
votes
1 answer

How to get the Hadoop path with Java/Scala API in Code Repositories

My need is to read other formats: JSON, binary, XML and infer the schema dynamically within a transform in Code Repositories and using Spark datasource api. Example: val df = spark.read.json() For that, I need an accessor to the…
2
votes
1 answer

In Workshop: How can I create buttons (functions?) so that user can segment by day, week, month or year

Background I've read about Typescript, but I am not a developer, so I am interested in how can I learn how can I create useful functions in Workshop. Question 1 How can I create buttons (functions?) so that I can create buttons for users to select…
2
votes
1 answer

date_format failing in the workbook environment

In a Palantir Foundry Code Workbook Spark SQL node (or in the Spark console in SQL mode), this works: SELECT date_format('2021-01-01',"yyyy-MM") 2021-01 But executing a pattern asking for a quarter doesn't: SELECT…
ivanhoe1982
  • 530
  • 1
  • 4
  • 14